aboutsummaryrefslogtreecommitdiffstats
path: root/src/libmdsclient
diff options
context:
space:
mode:
authorMattias Andrée <maandree@operamail.com>2015-08-25 08:06:45 +0200
committerMattias Andrée <maandree@operamail.com>2015-08-25 08:06:45 +0200
commitdfbfa84d1df5452825ded5500a2e42f6ec64a724 (patch)
tree7268e6b3bd63230a9ecaa0963feae2157087128f /src/libmdsclient
parentlibmds_connection: locking (diff)
downloadmds-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 'src/libmdsclient')
-rw-r--r--src/libmdsclient/comm.c4
-rw-r--r--src/libmdsclient/comm.h2
-rw-r--r--src/libmdsclient/proto-util.h2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/libmdsclient/comm.c b/src/libmdsclient/comm.c
index 1084e8b..b3091fb 100644
--- a/src/libmdsclient/comm.c
+++ b/src/libmdsclient/comm.c
@@ -90,13 +90,13 @@ int libmds_connection_send(libmds_connection_t* restrict this, const char* messa
r = libmds_connection_send_unlocked(this, message, length);
saved_errno = errno;
- libmds_connection_unlock(this);
+ (void) libmds_connection_unlock(this);
return errno = saved_errno, r;
}
int libmds_connection_send_unlocked(libmds_connection_t* restrict this, const char* message, size_t length)
{
- /* TODO */
+ return (void) this, (void) message, (void) length, 0; /* TODO */
}
diff --git a/src/libmdsclient/comm.h b/src/libmdsclient/comm.h
index 8f3f0d9..4a47b2a 100644
--- a/src/libmdsclient/comm.h
+++ b/src/libmdsclient/comm.h
@@ -150,7 +150,7 @@ int libmds_connection_send_unlocked(libmds_connection_t* restrict this, const ch
* will have been set accordingly on error
* @throws See pthread_mutex_unlock(3)
*/
-#define libmds_connection_unlock(this)
+#define libmds_connection_unlock(this) \
(errno = pthread_mutex_unlock(&((this)->mutex)), (errno ? 0 : -1))
diff --git a/src/libmdsclient/proto-util.h b/src/libmdsclient/proto-util.h
index f381c57..200e0db 100644
--- a/src/libmdsclient/proto-util.h
+++ b/src/libmdsclient/proto-util.h
@@ -443,7 +443,7 @@ int libmds_compose_v(char** restrict buffer, size_t* restrict buffer_size, size_
*/
__attribute__((nonnull(1)))
int libmds_next_message_id(uint32_t* restrict message_id, int (*test)(uint32_t message_id, void* data),
- void* data) ;
+ void* data);
#endif