mirror of
https://github.com/FEX-Emu/FEX.git
synced 2026-10-06 10:00:16 +02:00
Merge pull request #5721 from lioncash/win
AllocatorHooks: Amend VirtualProtect for Windows
This commit is contained in:
1 file changed
+2
-1
@@ -97,7 +97,8 @@ inline bool VirtualProtect(void* Ptr, size_t Size, ProtectOptions options) {
|
||||
LOGMAN_MSG_A_FMT("Unknown VirtualProtect options combination");
|
||||
}
|
||||
|
||||
return ::VirtualProtect(Ptr, Size, prot, nullptr) == 0;
|
||||
DWORD OldProt {};
|
||||
return ::VirtualProtect(Ptr, Size, prot, &OldProt) != 0;
|
||||
}
|
||||
|
||||
FEX_DEFAULT_VISIBILITY extern VirtualNamePtr VirtualName;
|
||||
|
||||
Reference in new issue
Block a user