aboutsummaryrefslogtreecommitdiff
path: root/monitor.c
diff options
context:
space:
mode:
Diffstat (limited to 'monitor.c')
-rw-r--r--monitor.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/monitor.c b/monitor.c
index 801a92601e..cadf422e3f 100644
--- a/monitor.c
+++ b/monitor.c
@@ -377,10 +377,9 @@ void monitor_protocol_event(MonitorEvent event, QObject *data)
}
QLIST_FOREACH(mon, &mon_list, entry) {
- if (!monitor_ctrl_mode(mon))
- return;
-
- monitor_json_emitter(mon, QOBJECT(qmp));
+ if (monitor_ctrl_mode(mon)) {
+ monitor_json_emitter(mon, QOBJECT(qmp));
+ }
}
QDECREF(qmp);
}