[libvirt PATCH v2 06/11] qemuMonitorGetBlockInfo: Remove superfluous variable "ret"

Tim Wiederhake twiederh at redhat.com
Tue Jul 6 12:37:54 UTC 2021


Signed-off-by: Tim Wiederhake <twiederh at redhat.com>
---
 src/qemu/qemu_monitor.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/src/qemu/qemu_monitor.c b/src/qemu/qemu_monitor.c
index dd0658f93c..933d4a0154 100644
--- a/src/qemu/qemu_monitor.c
+++ b/src/qemu/qemu_monitor.c
@@ -2103,7 +2103,6 @@ qemuDomainDiskInfoFree(void *value)
 GHashTable *
 qemuMonitorGetBlockInfo(qemuMonitor *mon)
 {
-    int ret;
     GHashTable *table;
 
     QEMU_CHECK_MONITOR_NULL(mon);
@@ -2111,9 +2110,7 @@ qemuMonitorGetBlockInfo(qemuMonitor *mon)
     if (!(table = virHashNew(qemuDomainDiskInfoFree)))
         return NULL;
 
-    ret = qemuMonitorJSONGetBlockInfo(mon, table);
-
-    if (ret < 0) {
+    if (qemuMonitorJSONGetBlockInfo(mon, table) < 0) {
         virHashFree(table);
         return NULL;
     }
-- 
2.31.1




More information about the libvir-list mailing list