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

Unified Diff: base/process/process_metrics_mac.cc

Issue 1543293004: Switch to standard integer types in base/process/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ssize_t Created 5 years 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 | « base/process/process_metrics_linux.cc ('k') | base/process/process_metrics_nacl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/process/process_metrics_mac.cc
diff --git a/base/process/process_metrics_mac.cc b/base/process/process_metrics_mac.cc
index 82acb0636b94bd941fd3861a05c0c4856a7f18c3..a8957e288dff29ebd6d9ac4ec3dc78d9b6c0198e 100644
--- a/base/process/process_metrics_mac.cc
+++ b/base/process/process_metrics_mac.cc
@@ -7,6 +7,8 @@
#include <mach/mach.h>
#include <mach/mach_vm.h>
#include <mach/shared_region.h>
+#include <stddef.h>
+#include <stdint.h>
#include <sys/sysctl.h>
#include "base/containers/hash_tables.h"
@@ -284,7 +286,7 @@ double ProcessMetrics::GetCPUUsage() {
timeradd(&system_timeval, &task_timeval, &task_timeval);
TimeTicks time = TimeTicks::Now();
- int64 task_time = TimeValToMicroseconds(task_timeval);
+ int64_t task_time = TimeValToMicroseconds(task_timeval);
if (last_system_time_ == 0) {
// First call, just set the last values.
@@ -293,8 +295,8 @@ double ProcessMetrics::GetCPUUsage() {
return 0;
}
- int64 system_time_delta = task_time - last_system_time_;
- int64 time_delta = (time - last_cpu_time_).InMicroseconds();
+ int64_t system_time_delta = task_time - last_system_time_;
+ int64_t time_delta = (time - last_cpu_time_).InMicroseconds();
DCHECK_NE(0U, time_delta);
if (time_delta == 0)
return 0;
« no previous file with comments | « base/process/process_metrics_linux.cc ('k') | base/process/process_metrics_nacl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698