]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: simplify monitor callbacks
authorEric Blake <eblake@redhat.com>
Fri, 18 Mar 2011 17:27:14 +0000 (11:27 -0600)
committerEric Blake <eblake@redhat.com>
Tue, 22 Mar 2011 23:16:08 +0000 (17:16 -0600)
commit18d68462e345cbaabb62253d4cedced092b43f3b
treeb37daddd52f221e94b71729a92c02014333f4ad6
parent6afa49a987d8dade58c956636f6c5f2077a52dc0
qemu: simplify monitor callbacks

A future patch will change reference counting idioms; consolidating
this pattern now makes the next patch smaller (touch only the new
macro rather than every caller).

* src/qemu/qemu_monitor.c (QEMU_MONITOR_CALLBACK): New helper.
(qemuMonitorGetDiskSecret, qemuMonitorEmitShutdown)
(qemuMonitorEmitReset, qemuMonitorEmitPowerdown)
(qemuMonitorEmitStop, qemuMonitorEmitRTCChange)
(qemuMonitorEmitWatchdog, qemuMonitorEmitIOError)
(qemuMonitorEmitGraphics): Use it to reduce duplication.
src/qemu/qemu_monitor.c