| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The Native Client Authors. All rights reserved. | 2 * Copyright (c) 2012 The Native Client Authors. All rights reserved. |
| 3 * Use of this source code is governed by a BSD-style license that can be | 3 * Use of this source code is governed by a BSD-style license that can be |
| 4 * found in the LICENSE file. | 4 * found in the LICENSE file. |
| 5 */ | 5 */ |
| 6 | 6 |
| 7 | 7 |
| 8 // NaCl inter-module communication primitives. | 8 // NaCl inter-module communication primitives. |
| 9 | 9 |
| 10 #include <windows.h> | 10 #include <windows.h> |
| 11 | 11 |
| 12 #include "native_client/src/shared/imc/nacl_imc.h" | 12 #include "native_client/src/shared/imc/nacl_imc.h" |
| 13 #include "native_client/src/shared/imc/nacl_imc_c.h" | 13 #include "native_client/src/shared/imc/nacl_imc_c.h" |
| 14 #include "native_client/src/shared/platform/nacl_check.h" | 14 #include "native_client/src/shared/platform/nacl_check.h" |
| 15 #include "native_client/src/shared/platform/nacl_log.h" | 15 #include "native_client/src/shared/platform/nacl_log.h" |
| 16 #include "native_client/src/trusted/desc/nacl_desc_effector.h" | 16 #include "native_client/src/trusted/desc/nacl_desc_effector.h" |
| 17 #include "native_client/src/trusted/service_runtime/include/sys/mman.h" | 17 #include "native_client/src/trusted/service_runtime/include/bits/mman.h" |
| 18 #include "native_client/src/trusted/service_runtime/nacl_config.h" | 18 #include "native_client/src/trusted/service_runtime/nacl_config.h" |
| 19 | 19 |
| 20 // This function is a no-op on Windows because there is no need to | 20 // This function is a no-op on Windows because there is no need to |
| 21 // override the Windows definition of NaClCreateMemoryObject(): it | 21 // override the Windows definition of NaClCreateMemoryObject(): it |
| 22 // already works inside the outer sandbox. | 22 // already works inside the outer sandbox. |
| 23 void NaClSetCreateMemoryObjectFunc(NaClCreateMemoryObjectFunc func) { | 23 void NaClSetCreateMemoryObjectFunc(NaClCreateMemoryObjectFunc func) { |
| 24 } | 24 } |
| 25 | 25 |
| 26 namespace nacl { | 26 namespace nacl { |
| 27 | 27 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 return start; | 96 return start; |
| 97 } | 97 } |
| 98 | 98 |
| 99 int Unmap(void* start, size_t length) { | 99 int Unmap(void* start, size_t length) { |
| 100 // TODO(shiki): Try from start to start + length | 100 // TODO(shiki): Try from start to start + length |
| 101 UnmapViewOfFile(start); | 101 UnmapViewOfFile(start); |
| 102 return 0; | 102 return 0; |
| 103 } | 103 } |
| 104 | 104 |
| 105 } // namespace nacl | 105 } // namespace nacl |
| OLD | NEW |