[Spice-devel] [PATCH 5/7] support QXL remove on spice_server_remove_interface

Frediano Ziglio fziglio at redhat.com
Wed Oct 14 08:37:34 PDT 2015


Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
---
 server/reds.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/server/reds.c b/server/reds.c
index 5d2ad9b..5993863 100644
--- a/server/reds.c
+++ b/server/reds.c
@@ -3234,6 +3234,13 @@ SPICE_GNUC_VISIBLE int spice_server_remove_interface(SpiceBaseInstance *sin)
         snd_detach_record(SPICE_CONTAINEROF(sin, SpiceRecordInstance, base));
     } else if (strcmp(interface->type, SPICE_INTERFACE_CHAR_DEVICE) == 0) {
         spice_server_char_device_remove_interface(sin);
+    } else if (strcmp(interface->type, SPICE_INTERFACE_QXL) == 0) {
+        QXLInstance *qxl;
+
+        qxl = SPICE_CONTAINEROF(sin, QXLInstance, base);
+        red_dispatcher_destroy(qxl);
+        free(qxl->st);
+        qxl->st = NULL;
     } else {
         spice_warning("VD_INTERFACE_REMOVING unsupported");
         return -1;
-- 
2.4.3



More information about the Spice-devel mailing list