[Spice-commits] client/controller.cpp

Hans de Goede jwrdegoede at kemper.freedesktop.org
Tue Mar 1 07:56:03 PST 2011

 client/controller.cpp |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit e9ee6cf914a206a7ecc3b378e2360e6b0a0b61cc
Author: Uri Lublin <uril at redhat.com>
Date:   Tue Mar 1 17:58:47 2011 +0200

    client: exit nicely for --controller with no SPICE_XPI_SOCKET (rhbz#644292)
    When starting spicec with --controller, SPICE_XPI_SOCKET environment
    variable must be defined so spicec and the controller can be connected.

diff --git a/client/controller.cpp b/client/controller.cpp
index 329c133..476d22e 100644
--- a/client/controller.cpp
+++ b/client/controller.cpp
@@ -44,6 +44,7 @@ Controller::Controller(ControllerInterface *handler)
     char *p_socket = getenv("SPICE_XPI_SOCKET");
     if (!p_socket) {
         LOG_ERROR("Failed to get a controller connection (SPICE_XPI_SOCKET)");
+        throw Exception("Failed to get a controller connection (SPICE_XPI_SOCKET)");
     strncpy(pipe_name, p_socket, sizeof(pipe_name));

More information about the Spice-commits mailing list