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

[libvirt] [PATCH] Fix 'virsh pool-list' locking issue



Running 'virsh pool-list' seems to deadlock libvirtd. Dan gave me some
debugging tips, and I managed to track it down to the poolGetAutostart
function. The attached patch fixes the issue.

Thanks,
Cole
diff --git a/src/storage_driver.c b/src/storage_driver.c
index 63593cc..2432a9a 100644
--- a/src/storage_driver.c
+++ b/src/storage_driver.c
@@ -911,8 +911,9 @@ storagePoolGetAutostart(virStoragePoolPtr obj,
     }
     ret = 0;
 
-    return 0;
 cleanup:
+    if (pool)
+        virStoragePoolObjUnlock(pool);
     return ret;
 }
 

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