summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Levy <alevy@redhat.com>2011-06-26 18:39:41 +0200
committerAlon Levy <alevy@redhat.com>2011-06-26 18:39:41 +0200
commit168e49a44a30fd5eebd7ff7ccf2ac0d0a78d3825 (patch)
treeb56fa53f8d929f8478d181b9d107ac9ff2a79d47
parent106299d9e9aa2bee323a3b2334ae69c17d8a9c88 (diff)
qxl: qxl_unmap_memory: cleanup xspice (fixes segfault if spice client connected when server shutsdown)xspice.v5
-rw-r--r--src/qxl_driver.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/qxl_driver.c b/src/qxl_driver.c
index bfbf444..9f96e1f 100644
--- a/src/qxl_driver.c
+++ b/src/qxl_driver.c
@@ -302,6 +302,12 @@ map_memory_helper(qxl_screen_t *qxl, int scrnIndex)
static void
qxl_unmap_memory(qxl_screen_t *qxl, int scrnIndex)
{
+#ifdef XSPICE
+ if (qxl->worker) {
+ qxl->worker->stop(qxl->worker);
+ spice_server_destroy(qxl->spice_server);
+ }
+#endif
unmap_memory_helper(qxl, scrnIndex);
qxl->ram = qxl->ram_physical = qxl->vram = qxl->rom = NULL;