Check for CLOCK_MONOTONIC_RAW

This should fix irungentoo/ProjectTox-Core#879 (and it's better than irungentoo/ProjectTox-Core#883).
This commit is contained in:
Ansa89 2014-05-28 14:34:17 +02:00
parent 68511f4e3f
commit 184e71ede2

View File

@ -234,7 +234,7 @@ uint64_t current_time_monotonic(void)
last_monotime = time;
#else
struct timespec monotime;
#if defined(__linux__)
#if defined(__linux__) && defined(CLOCK_MONOTONIC_RAW)
clock_gettime(CLOCK_MONOTONIC_RAW, &monotime);
#elif defined(__APPLE__)
clock_serv_t muhclock;