From 71d388d420e68ac77cd42f15f7e68cf5a6fb01b2 Mon Sep 17 00:00:00 2001 From: Yonit Halperin Date: Tue, 21 Aug 2012 11:51:56 +0300 Subject: spice: notify on vm state change only via spice_server_vm_start/stop QXLWorker->start/stop are deprecated since spice-server 0.11.2 Signed-off-by: Yonit Halperin Signed-off-by: Gerd Hoffmann --- ui/spice-core.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'ui/spice-core.c') diff --git a/ui/spice-core.c b/ui/spice-core.c index a515c946ca..1a7a773457 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -37,6 +37,7 @@ #include "migration.h" #include "monitor.h" #include "hw/hw.h" +#include "spice-display.h" /* core bits */ @@ -551,9 +552,11 @@ static void vm_change_state_handler(void *opaque, int running, { #if SPICE_SERVER_VERSION >= 0x000b02 /* 0.11.2 */ if (running) { + qemu_spice_display_start(); spice_server_vm_start(spice_server); } else { spice_server_vm_stop(spice_server); + qemu_spice_display_stop(); } #endif } @@ -755,6 +758,7 @@ int qemu_spice_add_interface(SpiceBaseInstance *sin) spice_server = spice_server_new(); spice_server_init(spice_server, &core_interface); } + return spice_server_add_interface(spice_server, sin); } -- cgit v1.2.1