From: "dengp...@chinatelecom.cn" <dengp...@chinatelecom.cn>

Memory free should be done in vdagent_disconnect using
qemu_input_handler_unregister, replace qemu_input_handler_deactivate
with that.

Signed-off-by: dengp...@chinatelecom.cn <dengp...@chinatelecom.cn>
Signed-off-by: liuy...@chinatelecom.cn <liuy...@chinatelecom.cn>
---
 ui/vdagent.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ui/vdagent.c b/ui/vdagent.c
index 4bf50f0c4d..645383b4ec 100644
--- a/ui/vdagent.c
+++ b/ui/vdagent.c
@@ -863,7 +863,7 @@ static void vdagent_disconnect(VDAgentChardev *vd)
     vdagent_reset_bufs(vd);
     vd->caps = 0;
     if (vd->mouse_hs) {
-        qemu_input_handler_deactivate(vd->mouse_hs);
+        qemu_input_handler_unregister(vd->mouse_hs);
     }
     if (vd->cbpeer.notifier.notify) {
         qemu_clipboard_peer_unregister(&vd->cbpeer);
-- 
2.27.0


Reply via email to