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

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

Issue 1328703003: Correct PROCESS_BASIC_INFORMATION for 64 bit Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Split test into smaller pieces. Created 5 years, 3 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
« no previous file with comments | « sandbox/win/src/policy_broker.h ('k') | sandbox/win/src/sandbox_nt_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/win/src/policy_broker.cc
diff --git a/sandbox/win/src/policy_broker.cc b/sandbox/win/src/policy_broker.cc
index dc5e18c28b9eb45c089ecdef68c1b0aaad154d28..c2d25bd55c25662e492f3becdca92144ffc55f76 100644
--- a/sandbox/win/src/policy_broker.cc
+++ b/sandbox/win/src/policy_broker.cc
@@ -38,7 +38,7 @@ SANDBOX_INTERCEPT NtExports g_nt;
if (NULL == g_nt.member) \
return false
-bool SetupNtdllImports(TargetProcess *child) {
+bool InitGlobalNt() {
HMODULE ntdll = ::GetModuleHandle(kNtdllName);
base::win::PEImage ntdll_image(ntdll);
@@ -75,6 +75,14 @@ bool SetupNtdllImports(TargetProcess *child) {
INIT_GLOBAL_RTL(wcslen);
INIT_GLOBAL_RTL(memcpy);
+ return true;
+}
+
+bool SetupNtdllImports(TargetProcess *child) {
+ if (!InitGlobalNt()) {
+ return false;
+ }
+
#ifndef NDEBUG
// Verify that the structure is fully initialized.
for (size_t i = 0; i < sizeof(g_nt)/sizeof(void*); i++)
« no previous file with comments | « sandbox/win/src/policy_broker.h ('k') | sandbox/win/src/sandbox_nt_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698