[PATCH] libvirt-guests: status: return non-zero when stopped

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Return 3 when the service is stopped, whether there
are saved guests or not.
---
 tools/libvirt-guests.sh.in | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/libvirt-guests.sh.in b/tools/libvirt-guests.sh.in
index 4f2e203..261c488 100644
--- a/tools/libvirt-guests.sh.in
+++ b/tools/libvirt-guests.sh.in
@@ -524,10 +524,11 @@ rh_status() {
     else
         if [ -f "$VAR_SUBSYS_LIBVIRT_GUESTS" ]; then
             gettext "started"; echo
+            RETVAL=0
         else
             gettext "stopped, with no saved guests"; echo
+            RETVAL=3
         fi
-        RETVAL=0
     fi
 }
 
-- 
1.8.1.5

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]