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

Side by Side Diff: base/time/time_posix.cc

Issue 18063004: Move timing files into base/time, install forwarding headers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ios Created 7 years, 5 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « base/time/time_mac.cc ('k') | base/time/time_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/time.h" 5 #include "base/time/time.h"
6 6
7 #include <sys/time.h> 7 #include <sys/time.h>
8 #include <time.h> 8 #include <time.h>
9 #if defined(OS_ANDROID) 9 #if defined(OS_ANDROID)
10 #include <time64.h> 10 #include <time64.h>
11 #endif 11 #endif
12 #include <unistd.h> 12 #include <unistd.h>
13 13
14 #include <limits> 14 #include <limits>
15 15
(...skipping 303 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 result.tv_usec = static_cast<suseconds_t>(Time::kMicrosecondsPerSecond) - 1; 319 result.tv_usec = static_cast<suseconds_t>(Time::kMicrosecondsPerSecond) - 1;
320 return result; 320 return result;
321 } 321 }
322 int64 us = us_ - kTimeTToMicrosecondsOffset; 322 int64 us = us_ - kTimeTToMicrosecondsOffset;
323 result.tv_sec = us / Time::kMicrosecondsPerSecond; 323 result.tv_sec = us / Time::kMicrosecondsPerSecond;
324 result.tv_usec = us % Time::kMicrosecondsPerSecond; 324 result.tv_usec = us % Time::kMicrosecondsPerSecond;
325 return result; 325 return result;
326 } 326 }
327 327
328 } // namespace base 328 } // namespace base
OLDNEW
« no previous file with comments | « base/time/time_mac.cc ('k') | base/time/time_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698