On 07/02/2018 11:22 AM, Markus Armbruster wrote:
monitor_json_emitter() and monitor_json_emitter_raw() are
unnecessarily general: they can send arbitrary JSON values, even
though we only ever use them for QMP, which may send only JSON
objects.

Specialize the argument from QObject * to QDict *, and rename to
qmp_queue_response(), qmp_send_response().

All callers but one lose an upcast.  The lone exception gains a
downcast; the next commit will get rid of it.

Signed-off-by: Markus Armbruster <arm...@redhat.com>
---
  monitor.c | 21 ++++++++++-----------
  1 file changed, 10 insertions(+), 11 deletions(-)


Reviewed-by: Eric Blake <ebl...@redhat.com>

And the new names are easier to tell apart.

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Reply via email to