summaryrefslogtreecommitdiffstats
path: root/glib
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2005-01-30 07:44:08 +0000
committerHavoc Pennington <hp@redhat.com>2005-01-30 07:44:08 +0000
commit98ad8a8ec6626f7f5c78915b6bdf2be688b4839f (patch)
treefb2744289e2f187aa7239d11bf8473fd186fa1ce /glib
parent41f52c96d651003b3d0a266a582d401228a8368e (diff)
2005-01-30 Havoc Pennington <hp@redhat.com>
* glib/dbus-gobject.c (introspect_properties): fix the XML generated * dbus/dbus-message.c (dbus_message_unref): add an in_cache flag which effectively detects the use of freed messages * glib/dbus-gobject.c (handle_introspect): modify and return the reply message instead of the incoming message * dbus/dbus-object-tree.c (handle_default_introspect_unlocked): gee, maybe it should SEND THE XML instead of just making a string and freeing it again ;-) * tools/dbus-print-message.c (print_message): improve printing of messages * configure.in: add debug-glib.service to the output
Diffstat (limited to 'glib')
-rw-r--r--glib/dbus-gobject.c10
-rw-r--r--glib/dbus-gparser.c2
2 files changed, 7 insertions, 5 deletions
diff --git a/glib/dbus-gobject.c b/glib/dbus-gobject.c
index 245ebf1e..abaf2e0e 100644
--- a/glib/dbus-gobject.c
+++ b/glib/dbus-gobject.c
@@ -204,7 +204,7 @@ introspect_properties (GObject *object, GString *xml)
g_string_append (xml, s);
g_string_append (xml, "\" type=\"");
g_string_append (xml, _dbus_gutils_type_to_string (dbus_type));
- g_string_append (xml, "\" access=\"\n");
+ g_string_append (xml, "\" access=\"");
if (can_set && can_get)
g_string_append (xml, "readwrite");
@@ -216,7 +216,7 @@ introspect_properties (GObject *object, GString *xml)
g_string_append (xml, "write");
}
- g_string_append (xml, "\">\n");
+ g_string_append (xml, "\"/>\n");
}
g_free (s);
@@ -329,12 +329,12 @@ handle_introspect (DBusConnection *connection,
if (ret == NULL)
g_error ("Out of memory");
- dbus_message_append_args (message,
+ dbus_message_append_args (ret,
DBUS_TYPE_STRING, &xml->str,
DBUS_TYPE_INVALID);
- dbus_connection_send (connection, message, NULL);
- dbus_message_unref (message);
+ dbus_connection_send (connection, ret, NULL);
+ dbus_message_unref (ret);
g_string_free (xml, TRUE);
diff --git a/glib/dbus-gparser.c b/glib/dbus-gparser.c
index 83922af4..963a5730 100644
--- a/glib/dbus-gparser.c
+++ b/glib/dbus-gparser.c
@@ -483,6 +483,8 @@ basic_type_from_string (const char *str)
return DBUS_TYPE_BYTE;
else if (strcmp (str, "object") == 0)
return DBUS_TYPE_OBJECT_PATH;
+ else if (strcmp (str, "variant") == 0)
+ return DBUS_TYPE_VARIANT;
else
return DBUS_TYPE_INVALID;
}