From 4d81a1d327be58e6d61dbf51a36275ae1c77ab19 Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Fri, 16 Dec 2011 06:32:09 +0100 Subject: [PATCH] dont raise errors if not needed --- PVE/API2/Qemu.pm | 6 ------ 1 file changed, 6 deletions(-) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 56fefff8..15c4ea3a 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -854,8 +854,6 @@ __PACKAGE__->register_method({ raise_param_exc({ skiplock => "Only root may use this option." }) if $skiplock && $user ne 'root@pam'; - die "VM $vmid already running\n" if PVE::QemuServer::check_running($vmid); - my $storecfg = PVE::Storage::config(); my $realcmd = sub { @@ -910,8 +908,6 @@ __PACKAGE__->register_method({ raise_param_exc({ skiplock => "Only root may use this option." }) if $skiplock && $user ne 'root@pam'; - die "VM $vmid not running\n" if !PVE::QemuServer::check_running($vmid); - my $storecfg = PVE::Storage::config(); my $realcmd = sub { @@ -1018,8 +1014,6 @@ __PACKAGE__->register_method({ raise_param_exc({ skiplock => "Only root may use this option." }) if $skiplock && $user ne 'root@pam'; - die "VM $vmid not running\n" if !PVE::QemuServer::check_running($vmid); - my $storecfg = PVE::Storage::config(); my $realcmd = sub {