mirror of
https://github.com/ptitSeb/box86.git
synced 2024-11-27 03:44:40 +08:00
Fixed some issue on tracking when protecting memory with PROT=0
This commit is contained in:
parent
666b5a6ce6
commit
dcc0355113
@ -957,6 +957,7 @@ void setProtection_mmap(uintptr_t addr, size_t size, uint32_t prot)
|
||||
else {
|
||||
mutex_lock(&mutex_prot);
|
||||
rb_set(mapallmem, addr, addr+size, 1);
|
||||
rb_unset(memprot, addr, addr+size);
|
||||
mutex_unlock(&mutex_prot);
|
||||
}
|
||||
}
|
||||
@ -970,6 +971,7 @@ void setProtection_elf(uintptr_t addr, size_t size, uint32_t prot)
|
||||
else {
|
||||
mutex_lock(&mutex_prot);
|
||||
rb_set(mapallmem, addr, addr+size, 1);
|
||||
rb_unset(memprot, addr, addr+size);
|
||||
mutex_unlock(&mutex_prot);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user