From 502f1bc19f336355f88eb25cfbfde36dbd866f24 Mon Sep 17 00:00:00 2001 From: Peter Kjellerstedt Date: Mon, 22 Jan 2007 09:20:55 +0000 Subject: Recognize _SC_MONOTONIC_CLOCK in sysconf() even if __NR_clock_getres is not defined. --- libc/unistd/sysconf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libc/unistd/sysconf.c b/libc/unistd/sysconf.c index c1b5da64d..66bcf9045 100644 --- a/libc/unistd/sysconf.c +++ b/libc/unistd/sysconf.c @@ -884,14 +884,14 @@ long int sysconf(int name) RETURN_NEG_1; #endif -#ifdef __NR_clock_getres case _SC_MONOTONIC_CLOCK: +#ifdef __NR_clock_getres /* Check using the clock_getres system call. */ if (clock_getres(CLOCK_MONOTONIC, NULL) >= 0) return _POSIX_VERSION; +#endif RETURN_NEG_1; -#endif } } libc_hidden_def(sysconf) -- cgit v1.2.3