]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemu: Fix name comparison in qemuMonitorJSONBlockIoThrottleInfo()
authorStefan Hajnoczi <stefanha@redhat.com>
Thu, 1 Nov 2012 17:20:56 +0000 (18:20 +0100)
committerCole Robinson <crobinso@redhat.com>
Sun, 9 Dec 2012 22:48:11 +0000 (17:48 -0500)
The string comparison logic was inverted and matched the first drive
that does *not* have the name we search for.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
(cherry picked from commit 23d47b33a2f8b524c32d556d6d55a7ccb0c5903a)

src/qemu/qemu_monitor_json.c

index 072736b31f1aa6883ccceac6adbc70e468edfa8a..e9ed927caaff80745bcba54393f9b7ffb7f9629c 100644 (file)
@@ -3518,7 +3518,7 @@ qemuMonitorJSONBlockIoThrottleInfo(virJSONValuePtr result,
             goto cleanup;
         }
 
-        if (STREQ(current_dev, device))
+        if (STRNEQ(current_dev, device))
             continue;
 
         found = 1;