]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: monitor: Introduce qemuMonitorJSONGetReply, a better qemuMonitorJSONCheckReply
authorPeter Krempa <pkrempa@redhat.com>
Thu, 1 Dec 2022 15:18:52 +0000 (16:18 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Fri, 2 Dec 2022 15:18:37 +0000 (16:18 +0100)
commita434684a57f95f65bc844f24240abd9031db1d2c
treec951592df55ced0a6aa6a08e6e88849e1df3d704
parentb4f8313787d1684e4b5c59b46f1403d5a8aa52ae
qemu: monitor: Introduce qemuMonitorJSONGetReply, a better qemuMonitorJSONCheckReply

Rather than simply checking that the 'return' field is of the expected
type we can directly return it as the caller is very likely going to use
it. Extract the code into the new function and add a wrapper to preserve
old functionality.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/qemu/qemu_monitor_json.c