aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRSDuck <rsduck@users.noreply.github.com>2020-11-16 17:03:24 +0100
committerRSDuck <rsduck@users.noreply.github.com>2020-11-16 17:03:24 +0100
commit1085cc14a43fe09b423a0e4334acd32823873d1c (patch)
treea5fddc586cc99ae25f106ff089d5615d714e9834
parent21dbca95434d18914b62287c0bb81677c030e6a3 (diff)
prevent use after free
-rw-r--r--src/NDS.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/NDS.cpp b/src/NDS.cpp
index d68045b..2b468be 100644
--- a/src/NDS.cpp
+++ b/src/NDS.cpp
@@ -210,13 +210,13 @@ bool Init()
void DeInit()
{
- delete ARM9;
- delete ARM7;
-
#ifdef JIT_ENABLED
ARMJIT::DeInit();
#endif
+ delete ARM9;
+ delete ARM7;
+
for (int i = 0; i < 8; i++)
delete DMAs[i];