all repos — mgba @ 2d6749f8c86b6c0ab9bf64f6666ad167f883226e

mGBA Game Boy Advance Emulator

3DS: Use linearAlloc instead of malloc
Jeffrey Pfau jeffrey@endrift.com
Wed, 10 Dec 2014 03:12:47 -0800
commit

2d6749f8c86b6c0ab9bf64f6666ad167f883226e

parent

ae71a7ec19ebb539a4b9c950b4102d29f7642924

1 files changed, 5 insertions(+), 2 deletions(-)

jump to
M src/platform/3ds/3ds-memory.csrc/platform/3ds/3ds-memory.c

@@ -5,10 +5,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this

* file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include "util/memory.h" +#include <3ds.h> + void* anonymousMemoryMap(size_t size) { - return malloc(size); + return linearAlloc(size); } void mappedMemoryFree(void* memory, size_t size) { - free(memory); + UNUSED(size); + linearFree(memory); }