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

Unified Diff: extensions/browser/api/system_cpu/cpu_info_provider_linux.cc

Issue 1549643002: Switch to standard integer types in extensions/browser/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@clean
Patch Set: 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
Index: extensions/browser/api/system_cpu/cpu_info_provider_linux.cc
diff --git a/extensions/browser/api/system_cpu/cpu_info_provider_linux.cc b/extensions/browser/api/system_cpu/cpu_info_provider_linux.cc
index 2ee8b74ef9c33380f32d7fc053b59987c5458fec..52c191a64ac2931f5779ff02374c433369fd8d22 100644
--- a/extensions/browser/api/system_cpu/cpu_info_provider_linux.cc
+++ b/extensions/browser/api/system_cpu/cpu_info_provider_linux.cc
@@ -4,6 +4,8 @@
#include "extensions/browser/api/system_cpu/cpu_info_provider.h"
+#include <stdint.h>
+
#include <cstdio>
#include <sstream>
@@ -47,8 +49,8 @@ bool CpuInfoProvider::QueryCpuTimePerProcessor(
if (line.compare(0, 3, "cpu") != 0)
continue;
- uint64 user = 0, nice = 0, sys = 0, idle = 0;
- uint32 pindex = 0;
+ uint64_t user = 0, nice = 0, sys = 0, idle = 0;
+ uint32_t pindex = 0;
int vals =
sscanf(line.c_str(),
"cpu%" PRIu32 " %" PRIu64 " %" PRIu64 " %" PRIu64 " %" PRIu64,
« no previous file with comments | « extensions/browser/api/system_cpu/cpu_info_provider.h ('k') | extensions/browser/api/system_display/display_info_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698