dbus-marshal-validate: Check brackets in signature nest correctly
[platform/upstream/dbus.git] / dbus / dbus-connection.c
index 420dfb8..e010579 100644 (file)
@@ -2334,10 +2334,11 @@ complete_pending_call_and_unlock (DBusConnection  *connection,
 {
   _dbus_pending_call_set_reply_unlocked (pending, message);
   _dbus_pending_call_ref_unlocked (pending); /* in case there's no app with a ref held */
+  _dbus_pending_call_start_completion_unlocked(pending);
   _dbus_connection_detach_pending_call_and_unlock (connection, pending);
+
   /* Must be called unlocked since it invokes app callback */
-  _dbus_pending_call_complete (pending);
+  _dbus_pending_call_finish_completion (pending);
   dbus_pending_call_unref (pending);
 }
 
@@ -2842,8 +2843,8 @@ dbus_connection_unref (DBusConnection *connection)
         {
           _dbus_warn_check_failed ("The last reference on a connection was dropped without closing the connection. This is a bug in an application. See dbus_connection_unref() documentation for details.\n%s",
                                    connection->shareable ?
-                                   "Most likely, the application called unref() too many times and removed a reference belonging to libdbus, since this is a shared connection.\n" : 
-                                    "Most likely, the application was supposed to call dbus_connection_close(), since this is a private connection.\n");
+                                   "Most likely, the application called unref() too many times and removed a reference belonging to libdbus, since this is a shared connection." :
+                                    "Most likely, the application was supposed to call dbus_connection_close(), since this is a private connection.");
           return;
         }
 #endif
@@ -2950,7 +2951,7 @@ dbus_connection_close (DBusConnection *connection)
     {
       CONNECTION_UNLOCK (connection);
 
-      _dbus_warn_check_failed ("Applications must not close shared connections - see dbus_connection_close() docs. This is a bug in the application.\n");
+      _dbus_warn_check_failed ("Applications must not close shared connections - see dbus_connection_close() docs. This is a bug in the application.");
       return;
     }
 #endif
@@ -3068,7 +3069,7 @@ dbus_connection_get_is_anonymous (DBusConnection *connection)
  * dbus_bus_get_id() instead (which is just a convenience wrapper
  * around the org.freedesktop.DBus.GetId method invoked on the bus).
  *
- * You can also get a machine ID; see dbus_get_local_machine_id() to
+ * You can also get a machine ID; see dbus_try_get_local_machine_id() to
  * get the machine you are on.  There isn't a convenience wrapper, but
  * you can invoke org.freedesktop.DBus.Peer.GetMachineId on any peer
  * to get the machine ID on the other end.
@@ -5316,6 +5317,12 @@ _dbus_connection_get_n_incoming (DBusConnection *connection)
   return connection->n_incoming;
 }
 
+dbus_bool_t
+_dbus_connection_is_overflowed (DBusConnection *connection)
+{
+  return _dbus_transport_get_overflowed (connection->transport);
+}
+
 /**
  * Gets the UNIX user ID of the connection if known.  Returns #TRUE if
  * the uid is filled in.  Always returns #FALSE on non-UNIX platforms
@@ -5775,7 +5782,7 @@ dbus_connection_remove_filter (DBusConnection            *connection,
 #ifndef DBUS_DISABLE_CHECKS
   if (filter == NULL)
     {
-      _dbus_warn_check_failed ("Attempt to remove filter function %p user data %p, but no such filter has been added\n",
+      _dbus_warn_check_failed ("Attempt to remove filter function %p user data %p, but no such filter has been added",
                                function, user_data);
       return;
     }
@@ -5894,7 +5901,7 @@ dbus_connection_register_object_path (DBusConnection              *connection,
 
   if (dbus_error_has_name (&error, DBUS_ERROR_OBJECT_PATH_IN_USE))
     {
-      _dbus_warn ("%s\n", error.message);
+      _dbus_warn ("%s", error.message);
       dbus_error_free (&error);
       return FALSE;
     }
@@ -5966,7 +5973,7 @@ dbus_connection_register_fallback (DBusConnection              *connection,
 
   if (dbus_error_has_name (&error, DBUS_ERROR_OBJECT_PATH_IN_USE))
     {
-      _dbus_warn ("%s\n", error.message);
+      _dbus_warn ("%s", error.message);
       dbus_error_free (&error);
       return FALSE;
     }