Remove compiler warnings when building Bionic.
Also add missing declarations to misc. functions.
Fix clearerr() implementation (previous was broken).
Handle feature test macros like _POSIX_C_SOURCE properly.
Change-Id: Icdc973a6b9d550a166fc2545f727ea837fe800c4
diff --git a/libc/bionic/system_properties.c b/libc/bionic/system_properties.c
index 5e3b9e7..767baa3 100644
--- a/libc/bionic/system_properties.c
+++ b/libc/bionic/system_properties.c
@@ -126,7 +126,7 @@
for(;;) {
serial = pi->serial;
while(SERIAL_DIRTY(serial)) {
- __futex_wait(&pi->serial, serial, 0);
+ __futex_wait((volatile void *)&pi->serial, serial, 0);
serial = pi->serial;
}
len = SERIAL_VALUE_LEN(serial);
@@ -164,7 +164,7 @@
} else {
n = pi->serial;
do {
- __futex_wait(&pi->serial, n, 0);
+ __futex_wait((volatile void *)&pi->serial, n, 0);
} while(n == pi->serial);
}
return 0;