notaz.gp2x.de
/
picodrive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9cdfc19
)
libretro: pass required arg to VirtualProtect
author
notaz
<notasas@gmail.com>
Wed, 3 Jan 2018 01:00:32 +0000
(
03:00
+0200)
committer
notaz
<notasas@gmail.com>
Wed, 3 Jan 2018 01:00:32 +0000
(
03:00
+0200)
platform/libretro/libretro.c
patch
|
blob
|
blame
|
history
diff --git
a/platform/libretro/libretro.c
b/platform/libretro/libretro.c
index
2bdd07d
..
42d30c2
100644
(file)
--- a/
platform/libretro/libretro.c
+++ b/
platform/libretro/libretro.c
@@
-451,7
+451,8
@@
int plat_mem_set_exec(void *ptr, size_t size)
{
int ret = -1;
#ifdef _WIN32
- ret = VirtualProtect(ptr, size, PAGE_EXECUTE_READWRITE, 0);
+ DWORD oldProtect = 0;
+ ret = VirtualProtect(ptr, size, PAGE_EXECUTE_READWRITE, &oldProtect);
if (ret == 0 && log_cb)
log_cb(RETRO_LOG_ERROR, "VirtualProtect(%p, %d) failed: %d\n", ptr, (int)size,
GetLastError());