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

Unified Diff: base/process_util_win.cc

Issue 10134001: Make sure that base::MessagePumpForUI from different modules are isolated from each other and add p… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: CR feedback. Created 8 years, 8 months 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
« base/message_pump_win.cc ('K') | « base/process_util.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/process_util_win.cc
diff --git a/base/process_util_win.cc b/base/process_util_win.cc
index 4fab4c68efc1da792e06b59f3ca07a5ed58ead11..9b2e100439cd24bdd060139a433eed2b3c91ceda 100644
--- a/base/process_util_win.cc
+++ b/base/process_util_win.cc
@@ -176,13 +176,14 @@ ProcessHandle GetCurrentProcessHandle() {
}
HMODULE GetModuleFromAddress(void* address) {
- HMODULE hinst = NULL;
- if (!::GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
+ HMODULE instance = NULL;
+ if (!::GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS |
+ GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT,
static_cast<char*>(address),
- &hinst)) {
+ &instance)) {
NOTREACHED();
}
- return hinst;
+ return instance;
}
bool OpenProcessHandle(ProcessId pid, ProcessHandle* handle) {
« base/message_pump_win.cc ('K') | « base/process_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698