virtio-serial-bus: Delete timer from list before free it
Signed-off-by: zhanghailiang <zhang.zhanghailiang@huawei.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Amit Shah <amit@kernel.org>
This commit is contained in:
parent
27ce0f3afc
commit
bdf4c4ec53
@ -724,6 +724,7 @@ static void virtio_serial_post_load_timer_cb(void *opaque)
|
||||
}
|
||||
}
|
||||
g_free(s->post_load->connected);
|
||||
timer_del(s->post_load->timer);
|
||||
timer_free(s->post_load->timer);
|
||||
g_free(s->post_load);
|
||||
s->post_load = NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user