]> xenbits.xensource.com Git - libvirt.git/commit
unlock the monitor when unwatching the monitor
authorWen Congyang <wency@cn.fujitsu.com>
Wed, 16 Mar 2011 06:54:28 +0000 (14:54 +0800)
committerEric Blake <eblake@redhat.com>
Thu, 17 Mar 2011 23:29:38 +0000 (17:29 -0600)
commit9741f3461b14e84816a21e1a9578adb7f1466fa2
tree8ae572a381995c17047ea8438a512c9a66bdda24
parent838f66968232a27d1867b4b2549e97bb58f6d490
unlock the monitor when unwatching the monitor

Steps to reproduce this bug:
# virsh qemu-monitor-command domain 'cpu_set 2 online' --hmp
The domain has 2 cpus, and we try to set the third cpu online.
The qemu crashes, and this command will hang.

The reason is that the refs is not 1 when we unwatch the monitor.
We lock the monitor, but we do not unlock it. So virCondWait()
will be blocked.

Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
src/qemu/qemu_monitor.c