summaryrefslogtreecommitdiffstats
path: root/sandbox/src
diff options
context:
space:
mode:
Diffstat (limited to 'sandbox/src')
-rw-r--r--sandbox/src/sandbox.cc3
-rw-r--r--sandbox/src/sandbox_policy_base.cc3
-rw-r--r--sandbox/src/target_process.cc5
3 files changed, 9 insertions, 2 deletions
diff --git a/sandbox/src/sandbox.cc b/sandbox/src/sandbox.cc
index f0b42bf..d8dceee 100644
--- a/sandbox/src/sandbox.cc
+++ b/sandbox/src/sandbox.cc
@@ -9,7 +9,8 @@
#include "sandbox/src/broker_services.h"
#include "sandbox/src/target_services.h"
-#ifdef _WIN64
+#if defined(_WIN64) && !defined(NACL_WIN64)
+// We allow building this code for Win64 as part of NaCl to enable development
#error Sandbox code was not tested on 64-bit Windows. See \
http://code.google.com/p/chromium/issues/detail?id=27218 for details \
and progress log.
diff --git a/sandbox/src/sandbox_policy_base.cc b/sandbox/src/sandbox_policy_base.cc
index ca41591a5..c294db9 100644
--- a/sandbox/src/sandbox_policy_base.cc
+++ b/sandbox/src/sandbox_policy_base.cc
@@ -389,6 +389,8 @@ bool PolicyBase::Ping(IPCInfo* ipc, void* arg1) {
uint32 tag = ipc->ipc_tag;
switch (tag) {
+#ifndef _WIN64 // TODO(gregoryd): To build this code for 64-bits Windows we
+ // need to make sure IPC is fully ported to Win64.
case IPC_PING1_TAG: {
uint32 cookie = bit_cast<uint32>(arg1);
COMPILE_ASSERT(sizeof(cookie) == sizeof(arg1), breaks_with_64_bit);
@@ -398,6 +400,7 @@ bool PolicyBase::Ping(IPCInfo* ipc, void* arg1) {
ipc->return_info.extended[1].unsigned_int = 2 * cookie;
return true;
}
+#endif
case IPC_PING2_TAG: {
CountedBuffer* io_buffer = reinterpret_cast<CountedBuffer*>(arg1);
if (sizeof(uint32) != io_buffer->Size())
diff --git a/sandbox/src/target_process.cc b/sandbox/src/target_process.cc
index fd65fea..1ba1885 100644
--- a/sandbox/src/target_process.cc
+++ b/sandbox/src/target_process.cc
@@ -184,13 +184,16 @@ DWORD TargetProcess::Create(const wchar_t* exe_path,
sandbox_thread_ = process_info.hThread;
sandbox_process_id_ = process_info.dwProcessId;
+#ifndef _WIN64 // TODO(gregoryd): This code does not build for Win64.
+ // It is safe to disable it since base_address_ is used for
+ // interception that is not supported on Win64 yet.
#pragma warning(push)
#pragma warning(disable: 4312)
// This cast generates a warning because it is 32 bit specific.
void* entry_point = reinterpret_cast<void*>(context.Eax);
#pragma warning(pop)
base_address_ = GetBaseAddress(exe_path, entry_point);
-
+#endif // _WIN64
*target_info = process_info;
return win_result;
}