qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PULL 5/6] net: Make qmp_query_rx_filter() with name argume


From: Stefan Hajnoczi
Subject: [Qemu-devel] [PULL 5/6] net: Make qmp_query_rx_filter() with name argument more obvious
Date: Fri, 25 Apr 2014 16:09:39 +0200

From: Markus Armbruster <address@hidden>

With a client name, the QMP command is specified to return a list of
one element.  This isn't locally obvious in the code.  Make it so.

Signed-off-by: Markus Armbruster <address@hidden>
Signed-off-by: Stefan Hajnoczi <address@hidden>
---
 net/net.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/net/net.c b/net/net.c
index bc9ed6d..ccb354a 100644
--- a/net/net.c
+++ b/net/net.c
@@ -1066,6 +1066,10 @@ RxFilterInfoList *qmp_query_rx_filter(bool has_name, 
const char *name,
                        " rx-filter querying", name);
             break;
         }
+
+        if (has_name) {
+            break;
+        }
     }
 
     if (filter_list == NULL && !error_is_set(errp) && has_name) {
-- 
1.9.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]