From 5840bd18a8e4d071d5594d4665631c8037eb88ea Mon Sep 17 00:00:00 2001 From: Thomas Lamprecht Date: Sun, 19 Nov 2023 20:05:50 +0100 Subject: [PATCH] btrfs: fix calling parent create_base method in fall-back If we want to forward to the create_base of the directory plugin while making that use our $class for the operations that call might do, we cannot use the -> notation (which would resolve the next actual implementation) but rather pass the class directly. But, DirPlugin reuses the create_base method from the base Plugin method, so we also need to call that, because on direct call notation the inheritance fallback to super methods isn't available. Reported in the forum: https://forum.proxmox.com/threads/95684/post-606535 Signed-off-by: Thomas Lamprecht --- src/PVE/Storage/BTRFSPlugin.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PVE/Storage/BTRFSPlugin.pm b/src/PVE/Storage/BTRFSPlugin.pm index 542f7f0..42815cb 100644 --- a/src/PVE/Storage/BTRFSPlugin.pm +++ b/src/PVE/Storage/BTRFSPlugin.pm @@ -262,7 +262,7 @@ sub create_base { # If we're not working with a 'raw' file, which is the only thing that's "different" for btrfs, # or a subvolume, we forward to the DirPlugin if ($format ne 'raw' && $format ne 'subvol') { - return PVE::Storage::DirPlugin::create_base(@_); + return PVE::Storage::Plugin::create_base(@_); } my $path = $class->filesystem_path($scfg, $volname);