summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosé Alburquerque <jaalburqu@svn.gnome.org>2011-06-09 15:38:01 -0400
committerJosé Alburquerque <jaalburqu@svn.gnome.org>2011-06-09 15:38:01 -0400
commit69d8fbe6ac19810ce7602f08b7170fe74aa4ffdc (patch)
tree65c377e128b8fc802f1ebc6e4589ec99376f5b4b
parent383d92d5647457593114cb1028cc7e8663ed5c71 (diff)
downloadglibmm-69d8fbe6ac19810ce7602f08b7170fe74aa4ffdc.tar.gz
Gio::DBus::Connection::emit_signal(): Say why convert empty strings.
* gio/src/dbusconnection.ccg (emit_signal): Explain why empty strings are converted to NULL when passed to the C API.
-rw-r--r--ChangeLog7
-rw-r--r--gio/src/dbusconnection.ccg4
2 files changed, 11 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 7485956a..0fd9d0db 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-06-09 José Alburquerque <jaalburqu@svn.gnome.org>
+
+ Gio::DBus::Connection::emit_signal(): Say why convert empty strings.
+
+ * gio/src/dbusconnection.ccg (emit_signal): Explain why empty strings
+ are converted to NULL when passed to the C API.
+
2011-06-08 José Alburquerque <jaalburqu@svn.gnome.org>
Gio::DBus::Connection::emit_signal(): Replace empty strings with NULL.
diff --git a/gio/src/dbusconnection.ccg b/gio/src/dbusconnection.ccg
index 64e24248..c8740660 100644
--- a/gio/src/dbusconnection.ccg
+++ b/gio/src/dbusconnection.ccg
@@ -761,6 +761,10 @@ void Connection::emit_signal(
{
GError* gerror = 0;
+ // Strings are checked to see if they are empty so that NULL can be passed
+ // for those strings to the C API. This is done because some strings such as
+ // the bus name can be NULL in the C API meaning that the signal should be
+ // emitted to all the listeners.
g_dbus_connection_emit_signal(gobj(),
(destination_bus_name.empty() ? 0 : destination_bus_name.c_str()),
(object_path.empty()? 0 : object_path.c_str()),