diff options
author | Mattias Andrée <maandree@operamail.com> | 2015-08-25 08:06:45 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2015-08-25 08:06:45 +0200 |
commit | dfbfa84d1df5452825ded5500a2e42f6ec64a724 (patch) | |
tree | 7268e6b3bd63230a9ecaa0963feae2157087128f /src/libmdsserver/client-list.h | |
parent | libmds_connection: locking (diff) | |
download | mds-dfbfa84d1df5452825ded5500a2e42f6ec64a724.tar.gz mds-dfbfa84d1df5452825ded5500a2e42f6ec64a724.tar.bz2 mds-dfbfa84d1df5452825ded5500a2e42f6ec64a724.tar.xz |
m + attributes
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | src/libmdsserver/client-list.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/libmdsserver/client-list.h b/src/libmdsserver/client-list.h index 077f9e4..34d23bc 100644 --- a/src/libmdsserver/client-list.h +++ b/src/libmdsserver/client-list.h @@ -58,6 +58,7 @@ typedef struct client_list * @param capacity The minimum initial capacity of the client list, 0 for default * @return Non-zero on error, `errno` will have been set accordingly */ +__attribute__((nonnull)) int client_list_create(client_list_t* restrict this, size_t capacity); /** @@ -66,6 +67,7 @@ int client_list_create(client_list_t* restrict this, size_t capacity); * * @param this The client list */ +__attribute__((nonnull)) void client_list_destroy(client_list_t* restrict this); /** @@ -75,6 +77,7 @@ void client_list_destroy(client_list_t* restrict this); * @param out Memory slot in which to store the new client list * @return Non-zero on error, `errno` will have been set accordingly */ +__attribute__((nonnull)) int client_list_clone(const client_list_t* restrict this, client_list_t* restrict out); /** @@ -84,6 +87,7 @@ int client_list_clone(const client_list_t* restrict this, client_list_t* restric * @param client The client to add * @return Non-zero on error, `errno` will be set accordingly */ +__attribute__((nonnull)) int client_list_add(client_list_t* restrict this, uint64_t client); /** @@ -92,6 +96,7 @@ int client_list_add(client_list_t* restrict this, uint64_t client); * @param this The list * @param client The client to remove */ +__attribute__((nonnull)) void client_list_remove(client_list_t* restrict this, uint64_t client); /** @@ -100,7 +105,8 @@ void client_list_remove(client_list_t* restrict this, uint64_t client); * @param this The list * @return The number of bytes to allocate to the output buffer */ -size_t client_list_marshal_size(const client_list_t* restrict this) __attribute__((pure)); +__attribute__((pure, nonnull)) +size_t client_list_marshal_size(const client_list_t* restrict this); /** * Marshals a client list @@ -108,6 +114,7 @@ size_t client_list_marshal_size(const client_list_t* restrict this) __attribute_ * @param this The list * @param data Output buffer for the marshalled data */ +__attribute__((nonnull)) void client_list_marshal(const client_list_t* restrict this, char* restrict data); /** @@ -118,6 +125,7 @@ void client_list_marshal(const client_list_t* restrict this, char* restrict data * @return Non-zero on error, `errno` will be set accordingly. * Destroy the list on error. */ +__attribute__((nonnull)) int client_list_unmarshal(client_list_t* restrict this, char* restrict data); |