aboutsummaryrefslogtreecommitdiffstats
path: root/src/mds-server/queued-interception.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mds-server/queued-interception.c')
-rw-r--r--src/mds-server/queued-interception.c41
1 files changed, 22 insertions, 19 deletions
diff --git a/src/mds-server/queued-interception.c b/src/mds-server/queued-interception.c
index ff00339..b74eb11 100644
--- a/src/mds-server/queued-interception.c
+++ b/src/mds-server/queued-interception.c
@@ -26,9 +26,10 @@
* @param this The client information
* @return The number of bytes to allocate to the output buffer
*/
-size_t queued_interception_marshal_size(void)
+size_t
+queued_interception_marshal_size(void)
{
- return sizeof(int64_t) + 3 * sizeof(int);
+ return sizeof(int64_t) + 3 * sizeof(int);
}
@@ -39,13 +40,14 @@ size_t queued_interception_marshal_size(void)
* @param data Output buffer for the marshalled data
* @return The number of bytes that have been written (everything will be written)
*/
-size_t queued_interception_marshal(const queued_interception_t* restrict this, char* restrict data)
+size_t
+queued_interception_marshal(const queued_interception_t *restrict this, char *restrict data)
{
- buf_set_next(data, int, QUEUED_INTERCEPTION_T_VERSION);
- buf_set_next(data, int64_t, this->priority);
- buf_set_next(data, int, this->modifying);
- buf_set_next(data, int, this->client->socket_fd);
- return queued_interception_marshal_size();
+ buf_set_next(data, int, QUEUED_INTERCEPTION_T_VERSION);
+ buf_set_next(data, int64_t, this->priority);
+ buf_set_next(data, int, this->modifying);
+ buf_set_next(data, int, this->client->socket_fd);
+ return queued_interception_marshal_size();
}
@@ -56,15 +58,16 @@ size_t queued_interception_marshal(const queued_interception_t* restrict this, c
* @param data In buffer with the marshalled data
* @return Zero on error, `errno` will be set accordingly, otherwise the number of read bytes.
*/
-size_t queued_interception_unmarshal(queued_interception_t* restrict this, char* restrict data)
+size_t
+queued_interception_unmarshal(queued_interception_t *restrict this, char *restrict data)
{
- this->client = NULL;
- /* buf_get_next(data, int, QUEUED_INTERCEPTION_T_VERSION); */
- buf_next(data, int, 1);
- buf_get_next(data, int64_t, this->priority);
- buf_get_next(data, int, this->modifying);
- buf_get_next(data, int, this->socket_fd);
- return queued_interception_marshal_size();
+ this->client = NULL;
+ /* buf_get_next(data, int, QUEUED_INTERCEPTION_T_VERSION); */
+ buf_next(data, int, 1);
+ buf_get_next(data, int64_t, this->priority);
+ buf_get_next(data, int, this->modifying);
+ buf_get_next(data, int, this->socket_fd);
+ return queued_interception_marshal_size();
}
@@ -74,8 +77,8 @@ size_t queued_interception_unmarshal(queued_interception_t* restrict this, char*
* @param data In buffer with the marshalled data
* @return The number of read bytes
*/
-size_t queued_interception_unmarshal_skip(void)
+size_t
+queued_interception_unmarshal_skip(void)
{
- return queued_interception_marshal_size();
+ return queued_interception_marshal_size();
}
-