From 6d6198304936a03681206646347dea6ef0a1d259 Mon Sep 17 00:00:00 2001 From: Gabriel Machado <97042217+GabrielBRDeveloper@users.noreply.github.com> Date: Thu, 24 Oct 2024 18:14:04 -0400 Subject: [PATCH] Fix crashes --- src/jni_driver.cpp | 1 + .../panda3ds/pandroid/app/preferences/GeneralPreferences.java | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/jni_driver.cpp b/src/jni_driver.cpp index 9df7c067..fbfae8ff 100644 --- a/src/jni_driver.cpp +++ b/src/jni_driver.cpp @@ -89,6 +89,7 @@ AlberFunction(void, Finalize)(JNIEnv* env, jobject obj) { emulator = nullptr; hidService = nullptr; renderer = nullptr; + romLoaded = false; } AlberFunction(jboolean, HasRomLoaded)(JNIEnv* env, jobject obj) { return romLoaded; } diff --git a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/preferences/GeneralPreferences.java b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/preferences/GeneralPreferences.java index 3861389a..cf16bc50 100644 --- a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/preferences/GeneralPreferences.java +++ b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/preferences/GeneralPreferences.java @@ -18,8 +18,6 @@ import com.panda3ds.pandroid.app.preferences.screen_editor.ScreenLayoutsPreferen import com.panda3ds.pandroid.data.config.GlobalConfig; import com.panda3ds.pandroid.utils.FileUtils; -import java.io.File; - public class GeneralPreferences extends BasePreferenceFragment implements ActivityResultCallback { private final ActivityResultContracts.OpenDocument openFolderContract = new ActivityResultContracts.OpenDocument(); private ActivityResultLauncher pickFileRequest;