summaryrefslogtreecommitdiffstats
path: root/dbus/dbus-marshal.c
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2003-01-19 03:33:35 +0000
committerHavoc Pennington <hp@redhat.com>2003-01-19 03:33:35 +0000
commit502fbda2201a4e7e50d687f42af29c82e66299bb (patch)
tree39aef7adb025c95dd016714dffd8577402a4669a /dbus/dbus-marshal.c
parent0363701c341796278041fb9ea7de80eaaf41479a (diff)
2003-01-18 Havoc Pennington <hp@pobox.com>
* dbus/dbus-transport-unix.c (unix_do_iteration): only do the reading/writing if read_watch != NULL or write_watch != NULL. * dbus/dbus-message.c (_dbus_message_loader_return_buffer): fix the message loader code to actually load message->header and message->body into the newly-created message. * dbus/dbus-transport-unix.c (check_write_watch): fix a mem leak in OOM case * dbus/dbus-connection.c (dbus_connection_set_max_message_size) (dbus_connection_get_max_message_size) (dbus_connection_set_max_live_messages_size) (dbus_connection_get_max_live_messages_size): implement some resource limitation functions * dbus/dbus-resources.c: new file implementing some of the resource limits stuff * dbus/dbus-message.c (dbus_message_iter_get_byte_array): add missing docs, add @todo to handle OOM etc. * dbus/dbus-marshal.c (_dbus_demarshal_byte_array): add missing docs
Diffstat (limited to 'dbus/dbus-marshal.c')
-rw-r--r--dbus/dbus-marshal.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/dbus/dbus-marshal.c b/dbus/dbus-marshal.c
index a6055806..395c2cce 100644
--- a/dbus/dbus-marshal.c
+++ b/dbus/dbus-marshal.c
@@ -401,6 +401,19 @@ _dbus_demarshal_string (DBusString *str,
return retval;
}
+/**
+ * Demarshals a byte array.
+ *
+ * @todo Should probably demarshal to a DBusString,
+ * having memcpy() in here is Evil(tm).
+ *
+ * @param str the string containing the data
+ * @param byte_order the byte order
+ * @param pos the position in the string
+ * @param new_pos the new position of the string
+ * @param array_len length of the demarshaled data
+ * @returns the demarshaled data.
+ */
unsigned char *
_dbus_demarshal_byte_array (DBusString *str,
int byte_order,