This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[COMMITTED PATCH] NaCl: Fix unused variable errors in lowlevellock-futex.h macros.
- From: Roland McGrath <roland at hack dot frob dot com>
- To: "GNU C. Library" <libc-alpha at sourceware dot org>
- Date: Wed, 20 Jan 2016 15:06:52 -0800 (PST)
- Subject: [COMMITTED PATCH] NaCl: Fix unused variable errors in lowlevellock-futex.h macros.
- Authentication-results: sourceware.org; auth=none
This unbreaks the trunk build on arm-nacl.
Thanks,
Roland
2016-01-20 Roland McGrath <roland@hack.frob.com>
* sysdeps/nacl/lowlevellock-futex.h
(lll_futex_wait, lll_futex_timed_wait, lll_futex_wake):
Always evaluate PRIVATE argument.
diff --git a/sysdeps/nacl/lowlevellock-futex.h b/sysdeps/nacl/lowlevellock-futex.h
index 5f7d459..5382f68 100644
--- a/sysdeps/nacl/lowlevellock-futex.h
+++ b/sysdeps/nacl/lowlevellock-futex.h
@@ -35,7 +35,8 @@
/* Wait while *FUTEXP == VAL for an lll_futex_wake call on FUTEXP. */
#define lll_futex_wait(futexp, val, private) \
- (- __nacl_irt_futex.futex_wait_abs ((volatile int *) (futexp), val, NULL))
+ ((void) (private), \
+ - __nacl_irt_futex.futex_wait_abs ((volatile int *) (futexp), val, NULL))
/* Wait until a lll_futex_wake call on FUTEXP, or TIMEOUT elapses. */
#define lll_futex_timed_wait(futexp, val, timeout, private) \
@@ -60,13 +61,15 @@
if (_err == 0) \
_err = __nacl_irt_futex.futex_wait_abs \
((volatile int *) (futexp), val, _to); \
- -_err; \
+ (void) (private); \
+ -_err; \
})
/* Wake up up to NR waiters on FUTEXP. */
#define lll_futex_wake(futexp, nr, private) \
({ \
int _woken; \
+ (void) (private); \
- __nacl_irt_futex.futex_wake ((volatile int *) (futexp), nr, &_woken); \
})