summaryrefslogtreecommitdiffstats
path: root/osdep
diff options
context:
space:
mode:
Diffstat (limited to 'osdep')
-rw-r--r--osdep/timer-darwin.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/osdep/timer-darwin.c b/osdep/timer-darwin.c
index c0fd20c041..9c5a2d6893 100644
--- a/osdep/timer-darwin.c
+++ b/osdep/timer-darwin.c
@@ -61,7 +61,8 @@ unsigned int GetTimer()
/* current time in milliseconds */
unsigned int GetTimerMS()
{
- return (unsigned int)(GetTimer() / 1000);
+ return (unsigned int)((mach_absolute_time() * timebase_ratio - startup_time)
+ * 1e3);
}
/* time spent between now and last call in seconds */