]> git.proxmox.com Git - pve-storage.git/commitdiff
fix #3555: BTRFS: call DirPlugin's free_image correctly
authorHannes Laimer <h.laimer@proxmox.com>
Fri, 30 Jul 2021 11:04:55 +0000 (13:04 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Fri, 30 Jul 2021 12:52:51 +0000 (14:52 +0200)
The method is only derived in the DirPlugin module from the base
Plugin, so we do not have it available there through a static module
method call using ::, but only when using a class dereference.

Other fix options would have been:

  PVE::Storage::Plugin::free_image(@_);

or:
  $class->SUPER::free_image($storeid, ...);

Signed-off-by: Hannes Laimer <h.laimer@proxmox.com>
[ Thomas: add some background to the commit message ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
PVE/Storage/BTRFSPlugin.pm

index 4596b301238f66f846770cdbd6aeac84677f56b3..411cab9530ead752e792c35eec85eea409b7288b 100644 (file)
@@ -410,7 +410,7 @@ sub free_image {
        $class->parse_volname($volname);
 
     if ($format ne 'subvol' && $format ne 'raw') {
-       return PVE::Storage::DirPlugin::free_image(@_);
+       return PVE::Storage::DirPlugin->free_image($storeid, $scfg, $volname, $isBase, $_format);
     }
 
     my $path = $class->filesystem_path($scfg, $volname);