]> xenbits.xensource.com Git - libvirt.git/commitdiff
logical: Fix @on argument type
authorJohn Ferlan <jferlan@redhat.com>
Tue, 4 Dec 2018 16:03:28 +0000 (11:03 -0500)
committerJohn Ferlan <jferlan@redhat.com>
Thu, 13 Dec 2018 12:09:42 +0000 (07:09 -0500)
It's only pass as 0 or 1 and used as a bool, let's just use a bool

Signed-off-by: John Ferlan <jferlan@redhat.com>
ACKed-by: Michal Privoznik <mprivozn@redhat.com>
src/storage/storage_backend_logical.c

index cad88756cb4b35d25be837b634aea7a51c77fec7..44cff61af76f978eead66bd746905db0045afb3e 100644 (file)
@@ -48,7 +48,7 @@ VIR_LOG_INIT("storage.storage_backend_logical");
 
 static int
 virStorageBackendLogicalSetActive(virStoragePoolObjPtr pool,
-                                  int on)
+                                  bool on)
 {
     int ret;
     virStoragePoolDefPtr def = virStoragePoolObjGetDef(pool);
@@ -731,7 +731,7 @@ virStorageBackendLogicalStartPool(virStoragePoolObjPtr pool)
      * that the pool's source devices match the pvs output.
      */
     if (!virStorageBackendLogicalMatchPoolSource(pool) ||
-        virStorageBackendLogicalSetActive(pool, 1) < 0)
+        virStorageBackendLogicalSetActive(pool, true) < 0)
         return -1;
 
     return 0;
@@ -858,7 +858,7 @@ virStorageBackendLogicalRefreshPool(virStoragePoolObjPtr pool)
 static int
 virStorageBackendLogicalStopPool(virStoragePoolObjPtr pool)
 {
-    if (virStorageBackendLogicalSetActive(pool, 0) < 0)
+    if (virStorageBackendLogicalSetActive(pool, false) < 0)
         return -1;
 
     return 0;