From: Dietmar Maurer Date: Wed, 8 Aug 2012 05:36:51 +0000 (+0200) Subject: fix for resize: remove useless permission checks X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=3b2773f606afc4aa93e6792ae341459c5b56a1fe;hp=614e3941a3ec73bbb2ccc6342e6512263a62d3bb;p=qemu-server.git fix for resize: remove useless permission checks --- diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 27d589f..3bedcd4 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -735,8 +735,6 @@ my $vmconfig_resize_disk = sub { if (PVE::QemuServer::drive_is_cdrom($drive)) { #cdrom die "you can't resize a cdrom"; - } else { - $rpcenv->check_vm_perm($authuser, $vmid, undef, ['VM.Config.Disk']); } if ($conf->{$opt}) { @@ -1798,7 +1796,7 @@ __PACKAGE__->register_method({ proxyto => 'node', description => "extend volume size.", permissions => { - check => ['perm', '/vms/{vmid}', $vm_config_perm_list, any => 1], + check => ['perm', '/vms/{vmid}', [ 'VM.Config.Disk' ]], }, parameters => { additionalProperties => 0,