diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2023-02-25 15:20:12 +0100 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2023-02-25 15:20:12 +0100 |
| commit | eb212cd27e104ce989e483536e8be6123c594255 (patch) | |
| tree | 3bba4e09eb731719cea36cbfdd75669c7d5788be /src/wrapped | |
| parent | b604dd0bccce7cd56e3532bd083e33568f3ecf46 (diff) | |
| download | box64-eb212cd27e104ce989e483536e8be6123c594255.tar.gz box64-eb212cd27e104ce989e483536e8be6123c594255.zip | |
[DYNAREC] Small imrvment in managing memory protection
Diffstat (limited to 'src/wrapped')
| -rwxr-xr-x | src/wrapped/wrappedlibc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wrapped/wrappedlibc.c b/src/wrapped/wrappedlibc.c index 1b84ab7b..7d24f736 100755 --- a/src/wrapped/wrappedlibc.c +++ b/src/wrapped/wrappedlibc.c @@ -2558,7 +2558,7 @@ EXPORT int my_mprotect(x64emu_t* emu, void *addr, unsigned long len, int prot) prot|=PROT_READ; // PROT_READ is implicit with PROT_WRITE on x86_64 int ret = mprotect(addr, len, prot); #ifdef DYNAREC - if(box64_dynarec) { + if(box64_dynarec && !ret) { if(prot& PROT_EXEC) addDBFromAddressRange((uintptr_t)addr, len); else |