projects
/
qemu.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bdb917b
)
virtio-serial: delete timer if active during exit
author
Amit Shah
<amit.shah@redhat.com>
Thu, 13 Dec 2012 10:24:43 +0000
(15:54 +0530)
committer
Amit Shah
<amit.shah@redhat.com>
Thu, 13 Dec 2012 10:31:26 +0000
(16:01 +0530)
The post_load timer was being freed, but not deleted. This could cause
problems when the timer is armed, but the device is hot-unplugged before
the callback is executed.
Signed-off-by: Amit Shah <amit.shah@redhat.com>
hw/virtio-serial-bus.c
patch
|
blob
|
history
diff --git
a/hw/virtio-serial-bus.c
b/hw/virtio-serial-bus.c
index 09d46593e2c27e2e1b3f691dff8a6f0f38e81b7b..fc0166ca7f845e9befa10581846c7d604283f82c 100644
(file)
--- a/
hw/virtio-serial-bus.c
+++ b/
hw/virtio-serial-bus.c
@@
-1038,6
+1038,7
@@
void virtio_serial_exit(VirtIODevice *vdev)
g_free(vser->ports_map);
if (vser->post_load) {
g_free(vser->post_load->connected);
+ qemu_del_timer(vser->post_load->timer);
qemu_free_timer(vser->post_load->timer);
g_free(vser->post_load);
}