1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-08-07 06:43:00 +03:00

Avoid comma operator warnings.

This commit is contained in:
Roland McGrath
2014-02-07 15:26:28 -08:00
parent d5b396c1c8
commit 32749f6cd2
4 changed files with 18 additions and 6 deletions

View File

@@ -35,7 +35,7 @@
typedef int mutex_t;
# define mutex_init(m) (*(m) = 0)
# define mutex_lock(m) ((*(m) = 1), 0)
# define mutex_lock(m) ({ *(m) = 1; 0; })
# define mutex_trylock(m) (*(m) ? 1 : ((*(m) = 1), 0))
# define mutex_unlock(m) (*(m) = 0)
# define MUTEX_INITIALIZER (0)