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

[libvirt] [PATCH] storage: Add comment to picking return value of qemu-img



Commit d7b2679253504d6defa9fc7159b572cfd6a25a95 introduced
a return value picking of qemu-img on '-h', but without any comment.
---
 src/storage/storage_backend.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/storage/storage_backend.c b/src/storage/storage_backend.c
index c8e19c8..b423d11 100644
--- a/src/storage/storage_backend.c
+++ b/src/storage/storage_backend.c
@@ -628,6 +628,9 @@ static int virStorageBackendQEMUImgBackingFormat(const char *qemuimg)
     virCommandSetOutputBuffer(cmd, &help);
     virCommandClearCaps(cmd);
 
+    /* qemuimg doesn't return zero exit status on -h,
+     * therefore we need to provide pointer for storing
+     * exit status, although we don't parse it any later */
     if (virCommandRun(cmd, &exitstatus) < 0)
         goto cleanup;
 
-- 
1.7.5.rc3


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