From ddba28b226a1b28761676d3f2cfe3ce0a6abe6df Mon Sep 17 00:00:00 2001 From: profi200 Date: Fri, 25 Aug 2023 13:17:56 +0200 Subject: [PATCH] Fixed a double free oopsie. --- source/arm11/open_agb_firm.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/source/arm11/open_agb_firm.c b/source/arm11/open_agb_firm.c index 6959851..b5b8e59 100644 --- a/source/arm11/open_agb_firm.c +++ b/source/arm11/open_agb_firm.c @@ -986,11 +986,9 @@ void oafUpdate(void) void oafFinish(void) { + // frameReadyEvent deleted by this function. + // gbaGfxHandler() will automatically terminate. LGYFB_deinit(); - if(g_frameReadyEvent != 0) - { - deleteEvent(g_frameReadyEvent); // gbaGfxHandler() will automatically terminate. - g_frameReadyEvent = 0; - } + g_frameReadyEvent = 0; LGY11_deinit(); }