summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnsa89 <ansalonistefano@gmail.com>2014-05-28 14:34:17 +0200
committerAnsa89 <ansalonistefano@gmail.com>2014-05-28 14:34:17 +0200
commit184e71ede2873964b638c9cfef39fcdb005e3a54 (patch)
treebd924a393e9e0fef0fd5b83544361f5e0a5ce2ce
parent68511f4e3f4a66c42021efab724db7768185b030 (diff)
Check for CLOCK_MONOTONIC_RAW
This should fix irungentoo/ProjectTox-Core#879 (and it's better than irungentoo/ProjectTox-Core#883).
-rw-r--r--toxcore/network.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/toxcore/network.c b/toxcore/network.c
index 20332362..bd5f8f56 100644
--- a/toxcore/network.c
+++ b/toxcore/network.c
@@ -234,7 +234,7 @@ uint64_t current_time_monotonic(void)
234 last_monotime = time; 234 last_monotime = time;
235#else 235#else
236 struct timespec monotime; 236 struct timespec monotime;
237#if defined(__linux__) 237#if defined(__linux__) && defined(CLOCK_MONOTONIC_RAW)
238 clock_gettime(CLOCK_MONOTONIC_RAW, &monotime); 238 clock_gettime(CLOCK_MONOTONIC_RAW, &monotime);
239#elif defined(__APPLE__) 239#elif defined(__APPLE__)
240 clock_serv_t muhclock; 240 clock_serv_t muhclock;