3DS: Use malloc instead of linearAlloc for most things
Jeffrey Pfau jeffrey@endrift.com
Mon, 31 Aug 2015 20:05:31 -0700
2 files changed,
4 insertions(+),
4 deletions(-)
M
src/platform/3ds/3ds-memory.c
→
src/platform/3ds/3ds-memory.c
@@ -10,10 +10,10 @@
#include <3ds.h> void* anonymousMemoryMap(size_t size) { - return linearAlloc(size); + return malloc(size); } void mappedMemoryFree(void* memory, size_t size) { UNUSED(size); - linearFree(memory); + free(memory); }
M
src/platform/3ds/main.c
→
src/platform/3ds/main.c
@@ -65,7 +65,7 @@ runner->context.gba->stream = &stream;
} GBAVideoSoftwareRendererCreate(&renderer); - renderer.outputBuffer = anonymousMemoryMap(256 * VIDEO_VERTICAL_PIXELS * 2); + renderer.outputBuffer = linearAlloc(256 * VIDEO_VERTICAL_PIXELS * 2); renderer.outputBufferStride = 256; runner->context.renderer = &renderer.d;@@ -259,7 +259,7 @@ GBAGUIRunloop(&runner);
GBAGUIDeinit(&runner); cleanup: - mappedMemoryFree(renderer.outputBuffer, 0); + linearFree(renderer.outputBuffer); if (logFile) { logFile->close(logFile);