Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(420)

Unified Diff: webrtc/base/timeutils.cc

Issue 2514553003: Change rtc::TimeNanos and rtc::TimeMicros return value from uint64_t to int64_t. (Closed)
Patch Set: Rebased, on top of fixed BoringSSL TimeCallback.' Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/base/timeutils.h ('k') | webrtc/base/timeutils_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/timeutils.cc
diff --git a/webrtc/base/timeutils.cc b/webrtc/base/timeutils.cc
index 658d0796adad16dd1663621a14aa65362c7962ea..c424f701f77fc2b642d4f25429f6d1aaf3e93811 100644
--- a/webrtc/base/timeutils.cc
+++ b/webrtc/base/timeutils.cc
@@ -39,7 +39,7 @@ ClockInterface* SetClockForTesting(ClockInterface* clock) {
return prev;
}
-uint64_t SystemTimeNanos() {
+int64_t SystemTimeNanos() {
int64_t ticks;
#if defined(WEBRTC_MAC)
static mach_timebase_info_data_t timebase;
@@ -88,7 +88,7 @@ int64_t SystemTimeMillis() {
return static_cast<int64_t>(SystemTimeNanos() / kNumNanosecsPerMillisec);
}
-uint64_t TimeNanos() {
+int64_t TimeNanos() {
if (g_clock) {
return g_clock->TimeNanos();
}
@@ -100,11 +100,11 @@ uint32_t Time32() {
}
int64_t TimeMillis() {
- return static_cast<int64_t>(TimeNanos() / kNumNanosecsPerMillisec);
+ return TimeNanos() / kNumNanosecsPerMillisec;
}
-uint64_t TimeMicros() {
- return static_cast<uint64_t>(TimeNanos() / kNumNanosecsPerMicrosec);
+int64_t TimeMicros() {
+ return TimeNanos() / kNumNanosecsPerMicrosec;
}
int64_t TimeAfter(int64_t elapsed) {
« no previous file with comments | « webrtc/base/timeutils.h ('k') | webrtc/base/timeutils_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698