diff options
author | John (J5) Palmieri <johnp@redhat.com> | 2004-05-28 19:09:00 +0000 |
---|---|---|
committer | John (J5) Palmieri <johnp@redhat.com> | 2004-05-28 19:09:00 +0000 |
commit | 1041b44d304cca543fe133b338b2021bbeffa913 (patch) | |
tree | dc849799ebdf3eb37c4b1abd0b17c08c9f14e5cd | |
parent | 841bf8a026632879f81cefa15df554956703b2b3 (diff) |
* fix for TODO item:
- the varargs dbus_message_get_args() needs to support OBJECT_PATH
and OBJECT_PATH_ARRAY
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | dbus/dbus-message.c | 21 | ||||
-rw-r--r-- | doc/TODO | 3 |
3 files changed, 26 insertions, 3 deletions
@@ -1,3 +1,8 @@ +2004-05-28 John (J5) Palmieri <johnp@redhat.com> + + * dbus/dbus-message.c (dbus_message_get_args): Added support for + OBJECT_PATH and OBJECT_PATH_ARRAY + 2004-05-28 Seth Nickell <seth@gnome.org> * python/examples/Makefile.am: diff --git a/dbus/dbus-message.c b/dbus/dbus-message.c index 9fa19668..feeebf0f 100644 --- a/dbus/dbus-message.c +++ b/dbus/dbus-message.c @@ -2480,6 +2480,23 @@ dbus_message_iter_get_args_valist (DBusMessageIter *iter, break; } + case DBUS_TYPE_OBJECT_PATH: + { + char **ptr; + + ptr = va_arg (var_args, char **); + + *ptr = dbus_message_iter_get_object_path (iter); + + if (!*ptr) + { + dbus_set_error (error, DBUS_ERROR_NO_MEMORY, NULL); + goto out; + } + + break; + } + case DBUS_TYPE_CUSTOM: { char **name; @@ -2548,6 +2565,10 @@ dbus_message_iter_get_args_valist (DBusMessageIter *iter, case DBUS_TYPE_STRING: err = !dbus_message_iter_get_string_array (iter, (char ***)data, len); break; + case DBUS_TYPE_OBJECT_PATH: + err = !dbus_message_iter_get_object_path_array (iter, (char ***)data, len); + break; + case DBUS_TYPE_NIL: case DBUS_TYPE_ARRAY: case DBUS_TYPE_CUSTOM: @@ -107,9 +107,6 @@ (though they are kind of a pita to pass in as size_t with the varargs, so maybe not - what does glib do with g_object_get()?) - - the varargs dbus_message_get_args() needs to support OBJECT_PATH - and OBJECT_PATH_ARRAY - - recursive dispatch, see dbus_connection_dispatch() - Perhaps the auth protocol should be able to negotiate a protocol |