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

Unified Diff: content/common/pepper_file_util.cc

Issue 1422773008: Fixing remaining VC++ 2015 64-bit build breaks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Some CR tweaks Created 5 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: content/common/pepper_file_util.cc
diff --git a/content/common/pepper_file_util.cc b/content/common/pepper_file_util.cc
index 6264faa5374422e65609de14913359318e0b66fa..e9e806d48da00e3e2266b954efbc435789301368 100644
--- a/content/common/pepper_file_util.cc
+++ b/content/common/pepper_file_util.cc
@@ -23,7 +23,9 @@ storage::FileSystemType PepperFileSystemTypeToFileSystemType(
int IntegerFromSyncSocketHandle(
const base::SyncSocket::Handle& socket_handle) {
#if defined(OS_WIN)
- return reinterpret_cast<int>(socket_handle);
+ // Cast through intptr_t and then int to make the truncation explicit.
+ // Handles are size-of-pointer but are always 32-bit values.
+ return static_cast<int>(reinterpret_cast<intptr_t>(socket_handle));
#elif defined(OS_POSIX)
return socket_handle;
#else

Powered by Google App Engine
This is Rietveld 408576698