Blame SOURCES/0003-os-Actually-use-the-computed-clockid-in-GetTimeInMic.patch

70130e
From 5f1e832694e57986c0185048a941b3af51b2f85f Mon Sep 17 00:00:00 2001
70130e
From: Julien Cristau <jcristau@debian.org>
70130e
Date: Tue, 5 Nov 2013 07:08:21 -0800
70130e
Subject: [PATCH 3/5] os: Actually use the computed clockid in GetTimeInMicros
70130e
70130e
The selection of which clock to use for this function was not actually
70130e
getting used when fetching the final clock value.
70130e
70130e
Reported-by: Julien Cristau <jcristau@debian.org>
70130e
Signed-off-by: Keith Packard <keithp@keithp.com>
70130e
---
70130e
 os/utils.c | 2 +-
70130e
 1 file changed, 1 insertion(+), 1 deletion(-)
70130e
70130e
diff --git a/os/utils.c b/os/utils.c
70130e
index 995f62a..fb20da7 100644
70130e
--- a/os/utils.c
70130e
+++ b/os/utils.c
70130e
@@ -480,7 +480,7 @@ GetTimeInMicros(void)
70130e
         else
70130e
             clockid = ~0L;
70130e
     }
70130e
-    if (clock_gettime(CLOCK_MONOTONIC, &tp) == 0)
70130e
+    if (clockid != ~0L && clock_gettime(clockid, &tp) == 0)
70130e
         return (CARD64) tp.tv_sec * (CARD64)1000000 + tp.tv_nsec / 1000;
70130e
 #endif
70130e
 
70130e
-- 
70130e
1.8.3.1
70130e