Prevent unused variable warnings when monotonic clock isn't available
This commit is contained in:
parent
13397feccf
commit
9ffb38d6be
@ -176,12 +176,12 @@ static __inline void DeleteCriticalSection(CRITICAL_SECTION *cs)
|
||||
static __inline ALuint timeGetTime(void)
|
||||
{
|
||||
#if _POSIX_TIMERS > 0
|
||||
static int hasmono = 0;
|
||||
struct timespec ts;
|
||||
int ret = -1;
|
||||
|
||||
#if defined(_POSIX_MONOTONIC_CLOCK) && (_POSIX_MONOTONIC_CLOCK >= 0)
|
||||
#if _POSIX_MONOTONIC_CLOCK == 0
|
||||
static int hasmono = 0;
|
||||
if(hasmono > 0 || (hasmono == 0 &&
|
||||
(hasmono=sysconf(_SC_MONOTONIC_CLOCK)) > 0))
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user