mirror of
https://github.com/red-prig/fpPS4.git
synced 2024-11-27 00:20:36 +00:00
+
This commit is contained in:
parent
6f230469b0
commit
a6e0cd17b0
@ -163,6 +163,7 @@ begin
|
||||
PAGE_EXECUTE_READWRITE);
|
||||
|
||||
Case prot of
|
||||
0,
|
||||
PAGE_NOACCESS :Result:=0;
|
||||
PAGE_READONLY :Result:=PROT_READ;
|
||||
PAGE_READWRITE :Result:=PROT_READ or PROT_WRITE;
|
||||
@ -195,7 +196,7 @@ function _VirtualReserve(Addr:Pointer;dwSize:PTRUINT;prot:Integer):Integer;
|
||||
begin
|
||||
Result:=0;
|
||||
if (Addr=nil) then Exit(-1);
|
||||
Addr:=VirtualAlloc(Addr,dwSize,MEM_RESERVE,__map_prot_page(prot));
|
||||
Addr:=VirtualAlloc(Addr,dwSize,MEM_RESERVE,PAGE_NOACCESS);
|
||||
if (Addr<>nil) then Exit;
|
||||
Result:=GetLastError;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user