repositories
/
deb_libcec.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f99b4d1
)
os-x: fixed GetTimeMs() on OS-X (hopefully). credits @bobo1on1
author
Lars Op den Kamp
<lars@opdenkamp.eu>
Sat, 3 Mar 2012 16:17:37 +0000
(17:17 +0100)
committer
Lars Op den Kamp
<lars@opdenkamp.eu>
Sat, 3 Mar 2012 16:18:42 +0000
(17:18 +0100)
src/lib/platform/util/timeutils.h
patch
|
blob
|
blame
|
history
diff --git
a/src/lib/platform/util/timeutils.h
b/src/lib/platform/util/timeutils.h
index b886f88a1cd58511b5cf03d9088af3456f6d54ac..bfbc5c42e444951dd368beffa012021cc0068469 100644
(file)
--- a/
src/lib/platform/util/timeutils.h
+++ b/
src/lib/platform/util/timeutils.h
@@
-78,7
+78,7
@@
namespace PLATFORM
inline int64_t GetTimeMs()
{
#if defined(__APPLE__)
- return (int64_t) (CVGetCurrentHostTime()
* 1000 / CVGetHostClockFrequency()
);
+ return (int64_t) (CVGetCurrentHostTime()
/ (int64_t)(CVGetHostClockFrequency() * 0.001 + 0.5
);
#elif defined(__WINDOWS__)
time_t rawtime;
time(&rawtime);