about summary refs log tree commit diff stats
path: root/src/elfs/elfloader.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/elfs/elfloader.c')
-rw-r--r--src/elfs/elfloader.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/elfs/elfloader.c b/src/elfs/elfloader.c
index 7cc4ec12..0e9feb75 100644
--- a/src/elfs/elfloader.c
+++ b/src/elfs/elfloader.c
@@ -216,7 +216,7 @@ int AllocLoadElfMemory(box64context_t* context, elfheader_t* head, int mainbin)
     printf_log(log_level, "Delta of %p (vaddr=%p) for Elf \"%s\"\n", (void*)offs, (void*)head->vaddr, head->name);
 
     head->image = image;
-    setProtection_mmap((uintptr_t)image, head->memsz, 0);
+    setProtection((uintptr_t)image, head->memsz, 0);
 
     head->multiblocks = (multiblock_t*)box_calloc(head->multiblock_n, sizeof(multiblock_t));
     head->tlsbase = AddTLSPartition(context, head->tlssize);
@@ -260,7 +260,7 @@ int AllocLoadElfMemory(box64context_t* context, elfheader_t* head, int mainbin)
                     try_mmap = 0;
                     printf_log(log_level, "Mapping failed, using regular mmap+read");
                 } else {
-                    setProtection_mmap((uintptr_t)p, head->multiblocks[n].asize, prot);
+                    setProtection((uintptr_t)p, head->multiblocks[n].asize, prot);
                     head->multiblocks[n].p = p;
 
                 }
@@ -285,7 +285,7 @@ int AllocLoadElfMemory(box64context_t* context, elfheader_t* head, int mainbin)
                     }
                     return 1;
                 }
-                setProtection_mmap((uintptr_t)p, head->multiblocks[n].asize, prot);
+                setProtection((uintptr_t)p, head->multiblocks[n].asize, prot);
                 head->multiblocks[n].p = p;
                 if(e->p_filesz) {
                     fseeko64(head->file, head->multiblocks[n].offs, SEEK_SET);