]> xenbits.xensource.com Git - libvirt.git/commit
Don't kill QEMU process when a monitor I/O parsing error occurs
authorDaniel P. Berrange <berrange@redhat.com>
Sun, 29 May 2011 12:37:29 +0000 (20:37 +0800)
committerDaniel Veillard <veillard@redhat.com>
Sun, 29 May 2011 12:37:29 +0000 (20:37 +0800)
commit4454a9efc728b91e791b1f14c26ea23a19d57f48
tree3c343a39170877a29ac3e72f4083cedfb5a63da3
parenta6135ec1e6fe0bbd90d01a6c1b5a993e795693bd
Don't kill QEMU process when a monitor I/O parsing error occurs

Currently whenever there is any failure with parsing the monitor,
this is treated in the same was as end-of-file (ie QEMU quit).
The domain is terminated, if not already dead.

With this change, failures in parsing the monitor stream do not
result in the death of QEMU. The guest continues running unchanged,
but all further use of the monitor will be disabled.

The VMM_FAILURE event will be emitted, and the mgmt application
can decide when to kill/restart the guest to re-gain control

* src/qemu/qemu_monitor.c, src/qemu/qemu_monitor.h: Run a
  different callback for monitor EOF vs error conditions.
* src/qemu/qemu_process.c: Emit VMM_FAILURE event when monitor
  fails
src/qemu/qemu_monitor.c
src/qemu/qemu_monitor.h
src/qemu/qemu_process.c