aboutsummaryrefslogtreecommitdiffstats
path: root/src/mds-server/client.h
diff options
context:
space:
mode:
authorMattias Andrée <maandree@operamail.com>2015-08-25 09:00:06 +0200
committerMattias Andrée <maandree@operamail.com>2015-08-25 09:00:06 +0200
commit527c082c88390fde29f555fe3720e0d55d9edc34 (patch)
tree141242290d3cfc1fc6fe280ebd4e77477943a4f7 /src/mds-server/client.h
parentm + attributes (diff)
downloadmds-527c082c88390fde29f555fe3720e0d55d9edc34.tar.gz
mds-527c082c88390fde29f555fe3720e0d55d9edc34.tar.bz2
mds-527c082c88390fde29f555fe3720e0d55d9edc34.tar.xz
attributes
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'src/mds-server/client.h')
-rw-r--r--src/mds-server/client.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/mds-server/client.h b/src/mds-server/client.h
index 24152f6..e60a0ed 100644
--- a/src/mds-server/client.h
+++ b/src/mds-server/client.h
@@ -154,6 +154,7 @@ typedef struct client
*
* @param this Memory slot in which to store the new client information
*/
+__attribute__((nonnull))
void client_initialise(client_t* restrict this);
/**
@@ -168,6 +169,7 @@ void client_initialise(client_t* restrict this);
* @param this The client information
* @return Zero on success, -1 on error
*/
+__attribute__((nonnull))
int client_initialise_threading(client_t* restrict this);
/**
@@ -175,6 +177,7 @@ int client_initialise_threading(client_t* restrict this);
*
* @param this The client information
*/
+__attribute__((nonnull))
void client_destroy(client_t* restrict this);
/**
@@ -183,7 +186,8 @@ void client_destroy(client_t* restrict this);
* @param this The client information
* @return The number of bytes to allocate to the output buffer
*/
-size_t client_marshal_size(const client_t* restrict this) __attribute__((pure));
+__attribute__((pure, nonnull))
+size_t client_marshal_size(const client_t* restrict this);
/**
* Marshals client information
@@ -192,6 +196,7 @@ size_t client_marshal_size(const client_t* restrict this) __attribute__((pure));
* @param data Output buffer for the marshalled data
* @return The number of bytes that have been written (everything will be written)
*/
+__attribute__((nonnull))
size_t client_marshal(const client_t* restrict this, char* restrict data);
/**
@@ -202,6 +207,7 @@ size_t client_marshal(const client_t* restrict this, char* restrict data);
* @return Zero on error, `errno` will be set accordingly, otherwise the
* number of read bytes. Destroy the client information on error.
*/
+__attribute__((nonnull))
size_t client_unmarshal(client_t* restrict this, char* restrict data);
/**
@@ -210,7 +216,8 @@ size_t client_unmarshal(client_t* restrict this, char* restrict data);
* @param data In buffer with the marshalled data
* @return The number of read bytes
*/
-size_t client_unmarshal_skip(char* restrict data) __attribute__((pure));
+__attribute__((pure, nonnull))
+size_t client_unmarshal_skip(char* restrict data);
#endif