* bus/driver.c (bus_driver_handle_reload_config): Make sure we send an
authorJohn (J5) Palmieri <johnp@redhat.com>
Mon, 7 Nov 2005 21:57:13 +0000 (21:57 +0000)
committerJohn (J5) Palmieri <johnp@redhat.com>
Mon, 7 Nov 2005 21:57:13 +0000 (21:57 +0000)
  empty reply so blocking calls don't block forever (Patch from Sjoerd
  Simons <sjoerd at luon.net>)

* AUTHORS: Add Robert McQueen for his work on the Python
  Bindings and other parts of D-Bus

AUTHORS
ChangeLog
bus/driver.c

diff --git a/AUTHORS b/AUTHORS
index 37be634..329b8d0 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -3,6 +3,7 @@ Philip Blundell <pb@nexus.co.uk>
 Anders Carlsson <andersca@gnome.org>
 Kristian Hogsberg  <krh@redhat.com>
 Alex Larsson <alexl@redhat.com>
+Robert McQueen <robot101@debian.org>
 Michael Meeks <michael@ximian.com>
 Seth Nickell <seth@gnome.org>
 John (J5) Palmieri <johnp@redhat.com>
index 0c6a898..de9ec1a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2005-11-07  John (J5) Palmieri  <johnp@redhat.com>
+
+       * bus/driver.c (bus_driver_handle_reload_config): Make sure we send an 
+       empty reply so blocking calls don't block forever (Patch from Sjoerd 
+       Simons <sjoerd at luon.net>)
+
+       * AUTHORS: Add Robert McQueen for his work on the Python
+       Bindings and other parts of D-Bus
+
 2005-11-07  Robert McQueen  <robot101@debian.org>
 
        * python/decorators.py: Change emit_signal function to use the
index 9e8df51..a6c4faf 100644 (file)
@@ -1094,23 +1094,34 @@ bus_driver_handle_reload_config (DBusConnection *connection,
                                 DBusError      *error)
 {
   BusContext *context;
-  dbus_bool_t retval;
+  DBusMessage *reply;
 
   _DBUS_ASSERT_ERROR_IS_CLEAR (error);
 
-  retval = FALSE;
-
+  reply = NULL;
+  
   context = bus_connection_get_context (connection);
   if (!bus_context_reload_config (context, error))
-    {
-      _DBUS_ASSERT_ERROR_IS_SET (error);
-      goto out;
-    }
+    goto failed;
 
-  retval = TRUE;
-  
- out:
-  return retval;
+  reply = dbus_message_new_method_return (message);
+  if (reply == NULL)
+    goto oom;
+
+  if (! bus_transaction_send_from_driver (transaction, connection, reply))
+    goto oom;
+
+  dbus_message_unref (reply);
+  return TRUE;
+
+ oom:
+  BUS_SET_OOM (error);
+
+ failed:
+  _DBUS_ASSERT_ERROR_IS_SET (error);
+  if (reply)
+    dbus_message_unref (reply);
+  return FALSE;
 }
 
 /* For speed it might be useful to sort this in order of