From e4455c234287e0324b8a79b9e9578c9aa09a25f9 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Wed, 14 Aug 2013 03:01:59 +0200 Subject: [PATCH] Fixed plat_mmap regression - Win32 now uses the same plat_mmap codepath --- platform/libretro.c | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/platform/libretro.c b/platform/libretro.c index a0591577..c02b2061 100644 --- a/platform/libretro.c +++ b/platform/libretro.c @@ -169,19 +169,6 @@ static void munmap(void *addr, size_t length) #endif void *plat_mmap(unsigned long addr, size_t size, int need_exec, int is_fixed) { -#ifndef _WIN32 - int flags = 0; - void *ret = mmap((void*)addr,size,PROT_READ | PROT_WRITE, flags, -1, 0); - if (addr != 0 && ret != (void *)addr) { - lprintf("warning: wanted to map @%08lx, got %p\n", - addr, ret); - - if (is_fixed) { - munmap(ret, size); - return NULL; - } - } -#else int flags = MAP_PRIVATE | MAP_ANONYMOUS; void *req, *ret; @@ -201,7 +188,6 @@ void *plat_mmap(unsigned long addr, size_t size, int need_exec, int is_fixed) return NULL; } } -#endif return ret; } -- 2.39.5