Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a25a677a authored by John Reck's avatar John Reck Committed by android-build-merger
Browse files

Merge "Fix NPE if app context is null" into pi-dev

am: a08a8569

Change-Id: I64ad0cbfa7e30cf298ba7e658cf0edab1e14630f
parents f054b173 a08a8569
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
@@ -1068,12 +1068,16 @@ public final class ThreadedRenderer {
            mInitialized = true;
            mAppContext = context.getApplicationContext();

            nSetDebuggingEnabled(
                    (mAppContext.getApplicationInfo().flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0
                    || Build.IS_DEBUGGABLE);
            initSched(renderProxy);

            if (mAppContext != null) {
                final boolean appDebuggable =
                        (mAppContext.getApplicationInfo().flags & ApplicationInfo.FLAG_DEBUGGABLE)
                        != 0;
                nSetDebuggingEnabled(appDebuggable || Build.IS_DEBUGGABLE);
                initGraphicsStats();
            }
        }

        private void initSched(long renderProxy) {
            try {