hmp: Fix warning from smatch (wrong argument in function call)
authorStefan Weil <sw@weilnetz.de>
Sun, 8 Feb 2015 14:40:48 +0000 (15:40 +0100)
committerLuiz Capitulino <lcapitulino@redhat.com>
Mon, 23 Feb 2015 15:55:20 +0000 (10:55 -0500)
Fix this warning:
hmp.c:414:38: warning: Using plain integer as NULL pointer

qmp_query_block expects a pointer argument, so passing false is wrong.

Cc: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
hmp.c

diff --git a/hmp.c b/hmp.c
index b47f331f4dbd114bfddf0d26dc11d6a51d794060..7690323e286c0407d34af5acf2280ac732913042 100644 (file)
--- a/hmp.c
+++ b/hmp.c
@@ -411,7 +411,7 @@ void hmp_info_block(Monitor *mon, const QDict *qdict)
 
     /* Print BlockBackend information */
     if (!nodes) {
-        block_list = qmp_query_block(false);
+        block_list = qmp_query_block(NULL);
     } else {
         block_list = NULL;
     }