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

Unified Diff: src/native_client/src/trusted/service_runtime/sel_addrspace.c

Issue 7068021: Dynamic loading: Fill pages with halts only when they are needed (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Fix log messages Created 9 years, 7 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
Index: src/native_client/src/trusted/service_runtime/sel_addrspace.c
diff --git a/src/native_client/src/trusted/service_runtime/sel_addrspace.c b/src/native_client/src/trusted/service_runtime/sel_addrspace.c
index b6684b79ea9932adc107b42babe9d2a380cf1cc8..63940612957083cbd2ff34ae5d193dda34a03c11 100644
--- a/src/native_client/src/trusted/service_runtime/sel_addrspace.c
+++ b/src/native_client/src/trusted/service_runtime/sel_addrspace.c
@@ -157,20 +157,10 @@ NaClErrorCode NaClMemoryProtection(struct NaClApp *nap) {
start_addr, region_size,
start_addr + region_size);
if (0 != region_size) {
- err = NaCl_mprotect((void *) start_addr,
- region_size,
- PROT_READ | PROT_EXEC);
- if (0 != err) {
- NaClLog(LOG_ERROR,
- ("NaClMemoryProtection: "
- "NaCl_mprotect(0x%08"NACL_PRIxPTR", "
- "0x%08"NACL_PRIxS", 0x%x) failed, "
- "error %d (trampoline)\n"),
- start_addr, region_size, PROT_READ | PROT_EXEC,
- err);
- return LOAD_MPROTECT_FAIL;
- }
/*
+ * Page protections for this region have already been set up by
+ * nacl_text.c.
+ *
* We record the mapping for consistency with other fixed
* mappings, but the record is not actually used. Overmapping is
* prevented by a separate range check, which is done by
« no previous file with comments | « src/native_client/src/trusted/service_runtime/nacl_text.c ('k') | src/native_client/src/trusted/service_runtime/sel_ldr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698