From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:56877) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qdkqs-0008HU-Jb for qemu-devel@nongnu.org; Mon, 04 Jul 2011 11:14:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qdkqq-0006ih-82 for qemu-devel@nongnu.org; Mon, 04 Jul 2011 11:14:22 -0400 Received: from mx1.redhat.com ([209.132.183.28]:45033) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qdkqp-0006i1-7W for qemu-devel@nongnu.org; Mon, 04 Jul 2011 11:14:19 -0400 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p64FEHVK013772 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 4 Jul 2011 11:14:18 -0400 From: Gerd Hoffmann Date: Mon, 4 Jul 2011 17:14:08 +0200 Message-Id: <1309792455-26825-3-git-send-email-kraxel@redhat.com> In-Reply-To: <1309792455-26825-1-git-send-email-kraxel@redhat.com> References: <1309792455-26825-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH 2/9] spice: catch spice server initialization failures. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann When the spice server initialization fails report this and exit instead of ignoring the error. Signed-off-by: Gerd Hoffmann --- ui/spice-core.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index dd9905b..e142452 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; -- 1.7.1