[libvirt] [PATCH 4/4] storage: list volumes even if its diskchain is broken

Guannan Ren gren at redhat.com
Thu Jul 18 11:32:17 UTC 2013


---
 src/storage/storage_backend_fs.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/storage/storage_backend_fs.c b/src/storage/storage_backend_fs.c
index d305b06..c6c019d 100644
--- a/src/storage/storage_backend_fs.c
+++ b/src/storage/storage_backend_fs.c
@@ -94,7 +94,9 @@ virStorageBackendProbeTarget(virStorageVolTargetPtr target,
 
     if (!(meta = virStorageFileGetMetadataFromFD(target->path, fd,
                                                  target->format))) {
-        ret = -1;
+        /* list volume even if its diskchain is broken */
+        virResetLastError();
+        ret = -3;
         goto error;
     }
 
-- 
1.8.3.1




More information about the libvir-list mailing list