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

Unified Diff: sandbox/win/src/win_utils.cc

Issue 2528243002: Fix silent truncations when extracting values from CheckedNumeric (Closed)
Patch Set: compile cleanup and fix 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
Index: sandbox/win/src/win_utils.cc
diff --git a/sandbox/win/src/win_utils.cc b/sandbox/win/src/win_utils.cc
index 9dfb2c9fb9204680ed0aa89a4d454153715edf72..51ae51d9fc04a8d499141de731751bc1b19c4166 100644
--- a/sandbox/win/src/win_utils.cc
+++ b/sandbox/win/src/win_utils.cc
@@ -489,7 +489,8 @@ void* GetProcessBaseAddress(HANDLE process) {
next_base += mem_info.RegionSize;
if (!next_base.IsValid())
return nullptr;
- current = reinterpret_cast<void*>(next_base.ValueOrDie());
+ current =
+ reinterpret_cast<void*>(static_cast<uintptr_t>(next_base.ValueOrDie()));
}
return nullptr;

Powered by Google App Engine
This is Rietveld 408576698