[Commits] SDL: Fixed NullPointerException if there's no singleton

libsdl.org revision control commits-owner at libsdl.org
Mon Sep 17 12:09:33 PDT 2018


details:   https://hg.libsdl.org/SDL/rev/56d508cebb46
changeset: 12194:56d508cebb46
user:      Sam Lantinga <slouken at libsdl.org>
date:      Mon Sep 17 12:08:05 2018 -0700
description:
Fixed NullPointerException if there's no singleton

diffstat:

 android-project/app/src/main/java/org/libsdl/app/SDLActivity.java |  4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diffs (14 lines):

diff -r a4c9aef03fe8 -r 56d508cebb46 android-project/app/src/main/java/org/libsdl/app/SDLActivity.java
--- a/android-project/app/src/main/java/org/libsdl/app/SDLActivity.java	Mon Sep 17 11:35:24 2018 -0700
+++ b/android-project/app/src/main/java/org/libsdl/app/SDLActivity.java	Mon Sep 17 12:08:05 2018 -0700
@@ -520,7 +520,9 @@
     /* The native thread has finished */
     public static void handleNativeExit() {
         SDLActivity.mSDLThread = null;
-        mSingleton.finish();
+        if (mSingleton != null) {
+            mSingleton.finish();
+        }
     }
 
 


More information about the commits mailing list