diff options
author | Lennart Poettering <lennart@poettering.net> | 2013-05-10 01:12:15 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2013-05-10 03:38:11 +0200 |
commit | f8e013f8bf476e6d61fb2e218c85e23032a46302 (patch) | |
tree | 184319e3255790107b879247ebd6d1ca925190c8 /src/systemd | |
parent | 2e996f4d4b642c5682c608c9692ad2ffae398ab2 (diff) |
bus: add sd_bus_message_append_string_space() for zero-copy string appending
Diffstat (limited to 'src/systemd')
-rw-r--r-- | src/systemd/sd-bus.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/systemd/sd-bus.h b/src/systemd/sd-bus.h index 2dab93d916..28c8536992 100644 --- a/src/systemd/sd-bus.h +++ b/src/systemd/sd-bus.h @@ -158,21 +158,20 @@ int sd_bus_message_set_destination(sd_bus_message *m, const char *destination); int sd_bus_message_append(sd_bus_message *m, const char *types, ...); int sd_bus_message_append_basic(sd_bus_message *m, char type, const void *p); +int sd_bus_message_append_array(sd_bus_message *m, char type, const void *ptr, size_t size); +int sd_bus_message_append_array_space(sd_bus_message *m, char type, size_t size, void **ptr); +int sd_bus_message_append_string_space(sd_bus_message *m, size_t size, char **s); int sd_bus_message_open_container(sd_bus_message *m, char type, const char *contents); int sd_bus_message_close_container(sd_bus_message *m); int sd_bus_message_read(sd_bus_message *m, const char *types, ...); int sd_bus_message_read_basic(sd_bus_message *m, char type, void *p); +int sd_bus_message_read_array(sd_bus_message *m, char type, const void **ptr, size_t *size); int sd_bus_message_enter_container(sd_bus_message *m, char type, const char *contents); int sd_bus_message_exit_container(sd_bus_message *m); int sd_bus_message_peek_type(sd_bus_message *m, char *type, const char **contents); int sd_bus_message_rewind(sd_bus_message *m, int complete); -int sd_bus_message_append_array(sd_bus_message *m, char type, const void *ptr, size_t size); -int sd_bus_message_append_array_ptr(sd_bus_message *m, char type, size_t size, void **ptr); - -int sd_bus_message_read_array(sd_bus_message *m, char type, const void **ptr, size_t *size); - /* Convenience calls */ int sd_bus_emit_signal(sd_bus *bus, const char *path, const char *interface, const char *member, const char *types, ...); |