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

Unified Diff: base/pickle.cc

Issue 1538743002: Switch to standard integer types in base/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: DEPS roll too 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/pickle.h ('k') | base/pickle_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/pickle.cc
diff --git a/base/pickle.cc b/base/pickle.cc
index 678c425e9439b76c24acfab1638b286ada81ed73..d83391bb524194b212a1f86ea0da26c1befd84ea 100644
--- a/base/pickle.cc
+++ b/base/pickle.cc
@@ -11,6 +11,7 @@
#include "base/bits.h"
#include "base/macros.h"
+#include "build/build_config.h"
namespace base {
@@ -71,7 +72,7 @@ const char* PickleIterator::GetReadPointerAndAdvance(int num_bytes) {
inline const char* PickleIterator::GetReadPointerAndAdvance(
int num_elements,
size_t size_element) {
- // Check for int32 overflow.
+ // Check for int32_t overflow.
int64_t num_bytes = static_cast<int64_t>(num_elements) * size_element;
int num_bytes32 = static_cast<int>(num_bytes);
if (num_bytes != static_cast<int64_t>(num_bytes32))
« no previous file with comments | « base/pickle.h ('k') | base/pickle_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698