about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2024-10-04 14:24:02 +0200
committerptitSeb <sebastien.chev@gmail.com>2024-10-04 14:24:02 +0200
commite6f56bf5faa09c0de38b59c2fb6ddbc6cbbdb484 (patch)
tree506e7a648fbd56e1b3bd34fcfffd72034fe75ea7
parent681c6f4e5ea62728590d82b3876978c76bff4c5f (diff)
downloadbox64-e6f56bf5faa09c0de38b59c2fb6ddbc6cbbdb484.tar.gz
box64-e6f56bf5faa09c0de38b59c2fb6ddbc6cbbdb484.zip
Fixed x86_64 build
-rw-r--r--src/wrapped/wrappedlibc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wrapped/wrappedlibc.c b/src/wrapped/wrappedlibc.c
index 3c820289..1482d9d9 100644
--- a/src/wrapped/wrappedlibc.c
+++ b/src/wrapped/wrappedlibc.c
@@ -2923,8 +2923,8 @@ EXPORT void* my_mmap64(x64emu_t* emu, void *addr, size_t length, int prot, int f
         prot|=PROT_READ;    // PROT_READ is implicit with PROT_WRITE on i386
     if((emu || box64_is32bits) && (box64_log>=LOG_DEBUG || box64_dynarec_log>=LOG_DEBUG)) {printf_log(LOG_NONE, "mmap64(%p, 0x%lx, 0x%x, 0x%x, %d, %ld) => ", addr, length, prot, flags, fd, offset);}
     int new_flags = flags;
-    #ifndef NOALIGN
     void* old_addr = addr;
+    #ifndef NOALIGN
     new_flags&=~MAP_32BIT;   // remove MAP_32BIT
     if((flags&MAP_32BIT) && !(flags&MAP_FIXED)) {
         // MAP_32BIT only exist on x86_64!