]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
Allow duration=0 for virsh nodesuspend
authorDaniel P. Berrange <berrange@redhat.com>
Fri, 30 Nov 2012 18:43:40 +0000 (18:43 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Fri, 30 Nov 2012 20:05:43 +0000 (20:05 +0000)
The virNodeSuspend API allows for a duration of 0, to mean no
timed wakup. virsh needlessly forbids this though

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
tools/virsh-host.c

index 3701f56674691a68f0746d216a5994094c74f115..3d13e016edfdc71f4dfeaf9615581ae41f15490d 100644 (file)
@@ -537,7 +537,7 @@ cmdNodeSuspend(vshControl *ctl, const vshCmd *cmd)
         return false;
     }
 
-    if (duration <= 0) {
+    if (duration < 0) {
         vshError(ctl, "%s", _("Invalid duration"));
         return false;
     }