render / rpms / libvirt

Forked from rpms/libvirt 9 months ago
Clone
Daniel P. Berrange 996d0e
diff -rup libvirt-0.6.0.orig/qemud/qemud.c libvirt-0.6.0.new/qemud/qemud.c
Daniel P. Berrange 996d0e
--- libvirt-0.6.0.orig/qemud/qemud.c	2009-02-18 10:56:34.000000000 +0000
Daniel P. Berrange 996d0e
+++ libvirt-0.6.0.new/qemud/qemud.c	2009-02-18 12:52:18.000000000 +0000
Daniel P. Berrange 996d0e
@@ -860,6 +860,10 @@ static struct qemud_server *qemudNetwork
Daniel P. Berrange 996d0e
     if (auth_unix_rw == REMOTE_AUTH_POLKIT ||
Daniel P. Berrange 996d0e
         auth_unix_ro == REMOTE_AUTH_POLKIT) {
Daniel P. Berrange 996d0e
         DBusError derr;
Daniel P. Berrange 996d0e
+
Daniel P. Berrange 996d0e
+        dbus_connection_set_change_sigpipe(FALSE);
Daniel P. Berrange 996d0e
+        dbus_threads_init_default();
Daniel P. Berrange 996d0e
+
Daniel P. Berrange 996d0e
         dbus_error_init(&derr);
Daniel P. Berrange 996d0e
         server->sysbus = dbus_bus_get(DBUS_BUS_SYSTEM, &derr);
Daniel P. Berrange 996d0e
         if (!(server->sysbus)) {
Daniel P. Berrange 996d0e
@@ -868,6 +872,7 @@ static struct qemud_server *qemudNetwork
Daniel P. Berrange 996d0e
             dbus_error_free(&derr);
Daniel P. Berrange 996d0e
             goto cleanup;
Daniel P. Berrange 996d0e
         }
Daniel P. Berrange 996d0e
+        dbus_connection_set_exit_on_disconnect(server->sysbus, FALSE);
Daniel P. Berrange 996d0e
     }
Daniel P. Berrange 996d0e
 #endif
Daniel P. Berrange 996d0e
 
Daniel P. Berrange 996d0e
diff -rup libvirt-0.6.0.orig/src/node_device_hal.c libvirt-0.6.0.new/src/node_device_hal.c
Daniel P. Berrange 996d0e
--- libvirt-0.6.0.orig/src/node_device_hal.c	2009-01-16 12:44:22.000000000 +0000
Daniel P. Berrange 996d0e
+++ libvirt-0.6.0.new/src/node_device_hal.c	2009-02-18 12:52:48.000000000 +0000
Daniel P. Berrange 996d0e
@@ -685,6 +685,9 @@ static int halDeviceMonitorStartup(void)
Daniel P. Berrange 996d0e
     nodeDeviceLock(driverState);
Daniel P. Berrange 996d0e
 
Daniel P. Berrange 996d0e
     /* Allocate and initialize a new HAL context */
Daniel P. Berrange 996d0e
+    dbus_connection_set_change_sigpipe(FALSE);
Daniel P. Berrange 996d0e
+    dbus_threads_init_default();
Daniel P. Berrange 996d0e
+
Daniel P. Berrange 996d0e
     dbus_error_init(&err;;
Daniel P. Berrange 996d0e
     hal_ctx = libhal_ctx_new();
Daniel P. Berrange 996d0e
     if (hal_ctx == NULL) {
Daniel P. Berrange 996d0e
@@ -696,6 +699,8 @@ static int halDeviceMonitorStartup(void)
Daniel P. Berrange 996d0e
         fprintf(stderr, "%s: dbus_bus_get failed\n", __FUNCTION__);
Daniel P. Berrange 996d0e
         goto failure;
Daniel P. Berrange 996d0e
     }
Daniel P. Berrange 996d0e
+    dbus_connection_set_exit_on_disconnect(dbus_conn, FALSE);
Daniel P. Berrange 996d0e
+
Daniel P. Berrange 996d0e
     if (!libhal_ctx_set_dbus_connection(hal_ctx, dbus_conn)) {
Daniel P. Berrange 996d0e
         fprintf(stderr, "%s: libhal_ctx_set_dbus_connection failed\n",
Daniel P. Berrange 996d0e
                 __FUNCTION__);