> Am 22.12.2014 um 16:36 schrieb Dietmar Maurer <diet...@proxmox.com>:
> 
> 
>>    $timeout = 60 if !defined($timeout);
>> -    my $config = load_config($vmid);
> 
> Oh, we already have $conf loaded - good catch!
> 
>>    eval {
>>        if ($shutdown) {
>> -        if ($config->{agent}) {
>> +        if (!$nocheck && $conf->{agent}) {
>>            vm_qmp_command($vmid, { execute => "guest-shutdown" }, $nocheck);
> 
> we pass $nockeck to  vm_qmp_command, so the following should be good enough:
> 
> -        if ($config->{agent}) {
> +        if ($conf->{agent}) {

But conf may be undefined if we do not load the config. So check for a key 
might issue a warning.

> 
> 
> Would you mind to cleanup the patch? Or can I simply commit a modified 
> version?
> 
_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to