43fe83
From 8cb402b248c072f5a9e440e33fae60bd77d06a69 Mon Sep 17 00:00:00 2001
43fe83
Message-Id: <8cb402b248c072f5a9e440e33fae60bd77d06a69.1379193140.git.jdenemar@redhat.com>
43fe83
From: Jiri Denemark <jdenemar@redhat.com>
43fe83
Date: Wed, 11 Sep 2013 15:49:48 +0200
43fe83
Subject: [PATCH] virsh domjobinfo: Do not return 1 if job is NONE
43fe83
43fe83
https://bugzilla.redhat.com/show_bug.cgi?id=1006864
43fe83
43fe83
Commit 38ab1225 changed the default value of ret from true to false but
43fe83
forgot to set ret = true when job is NONE. Thus, virsh domjobinfo
43fe83
returned 1 when there was no job running for a domain but it used to
43fe83
(and should) return 0 in this case.
43fe83
43fe83
(cherry picked from commit f084caae7c5db8ae03e7fafce164c73f65681843)
43fe83
---
43fe83
 tools/virsh-domain.c | 1 +
43fe83
 1 file changed, 1 insertion(+)
43fe83
43fe83
diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c
43fe83
index f35a3c5..bf5f425 100644
43fe83
--- a/tools/virsh-domain.c
43fe83
+++ b/tools/virsh-domain.c
43fe83
@@ -4995,6 +4995,7 @@ cmdDomjobinfo(vshControl *ctl, const vshCmd *cmd)
43fe83
     case VIR_DOMAIN_JOB_NONE:
43fe83
     default:
43fe83
         vshPrint(ctl, "%-12s\n", _("None"));
43fe83
+        ret = true;
43fe83
         goto cleanup;
43fe83
     }
43fe83
 
43fe83
-- 
43fe83
1.8.3.2
43fe83