]> git.proxmox.com Git - mirror_qemu.git/commit
iothread: fix crash with invalid properties
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Tue, 21 Aug 2018 10:07:16 +0000 (12:07 +0200)
committerFam Zheng <famz@redhat.com>
Fri, 12 Oct 2018 01:46:14 +0000 (09:46 +0800)
commit14a2d11825ddc37d6547a80704ae6450e9e376c7
tree6f12f5a30b5730e165b12059447386eb0afcf072
parent75e50c80e051423a6f55a34ee4a1eec842444a5b
iothread: fix crash with invalid properties

-object iothread,id=foo,? will crash qemu:

qemu-system-x86_64:qemu-thread-posix.c:128: qemu_cond_destroy: Assertion `cond->initialized' failed.

Use thread_id != -1 to check if iothread_complete() finished
successfully and the mutex/cond have been initialized.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20180821100716.13803-1-marcandre.lureau@redhat.com>
Signed-off-by: Fam Zheng <famz@redhat.com>
iothread.c