summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2011-06-15 13:11:33 +0200
committerGerd Hoffmann <kraxel@redhat.com>2011-07-04 15:35:12 +0200
commitfba810f1f67b411c209aa0e3d90724127cbd9c0f (patch)
tree56422a64af451684709277b7cfb05febdbb02104
parent638f4e47798725cef2a5ae5bf83d508fbde36605 (diff)
spice: catch spice server initialization failures.
When the spice server initialization fails report this and exit instead of ignoring the error. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-rw-r--r--ui/spice-core.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/ui/spice-core.c b/ui/spice-core.c
index dd9905be3..e142452bb 100644
--- a/ui/spice-core.c
+++ b/ui/spice-core.c
@@ -602,7 +602,10 @@ void qemu_spice_init(void)
qemu_opt_foreach(opts, add_channel, NULL, 0);
- spice_server_init(spice_server, &core_interface);
+ if (0 != spice_server_init(spice_server, &core_interface)) {
+ fprintf(stderr, "failed to initialize spice server");
+ exit(1);
+ };
using_spice = 1;
migration_state.notify = migration_state_notifier;