diff options
author | Garrett D'Amore <garrett@damore.org> | 2018-05-23 13:18:59 -0700 |
---|---|---|
committer | Garrett D'Amore <garrett@damore.org> | 2018-05-23 13:20:02 -0700 |
commit | 4f4ac6691daf6ee0509f346bed6d0cae4ec4f45c (patch) | |
tree | c8c0314f9bef4acad8fe65ab4f10c6e8a2779e2b /src/utils | |
parent | d27d3b780ebe1b987d180773ea071fd6a89625a6 (diff) | |
download | nanomsg-4f4ac6691daf6ee0509f346bed6d0cae4ec4f45c.tar.gz |
fixes #976 Enable all warnings by default
While here we fix a few warnings we found, and enable coverage
building with CMake. This is in anticipation of switching to
Circle CI.
Diffstat (limited to 'src/utils')
-rw-r--r-- | src/utils/atomic.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/utils/atomic.c b/src/utils/atomic.c index 4018c7e..f82d0b9 100644 --- a/src/utils/atomic.c +++ b/src/utils/atomic.c @@ -22,6 +22,7 @@ #include "atomic.h" #include "err.h" +#include "attr.h" void nn_atomic_init (struct nn_atomic *self, uint32_t n) { @@ -31,12 +32,16 @@ void nn_atomic_init (struct nn_atomic *self, uint32_t n) #endif } +#if defined NN_ATOMIC_MUTEX void nn_atomic_term (struct nn_atomic *self) { -#if defined NN_ATOMIC_MUTEX nn_mutex_term (&self->sync); -#endif } +#else +void nn_atomic_term (NN_UNUSED struct nn_atomic *self) +{ +} +#endif uint32_t nn_atomic_inc (struct nn_atomic *self, uint32_t n) { |