]> git.proxmox.com Git - mirror_qemu.git/commit
qmp: Simplify monitor_qmp_respond()
authorMarkus Armbruster <armbru@redhat.com>
Tue, 3 Jul 2018 08:53:52 +0000 (10:53 +0200)
committerMarkus Armbruster <armbru@redhat.com>
Tue, 3 Jul 2018 21:18:56 +0000 (23:18 +0200)
commit7cb2123f226a88fddcb9a3673c658c818ee6daed
tree7d166fe930e0804e603e69cfbdde7052203207db
parent1816604b62f4c5ac1032374a941638f2fe199104
qmp: Simplify monitor_qmp_respond()

monitor_qmp_respond() takes both a response object and an error
object.  If an error object is non-null, the response object must be
null, and the response is built from the error object.

Of the two callers, one always passes a null response object, and one
a null error object.  Move building the response object from the error
object to the latter, and drop the error object parameter.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-Id: <20180703085358.13941-27-armbru@redhat.com>
monitor.c