Crash when handling intent |
|||||
Issue description
Repro:
1. Use slow device like a Nexus One
2. Open Blimp
Expected result:
The normal startup flow.
Actual result:
Crash, because mToolbar is not set yet in BlimpRendererActivity
Stacktrace:
04-06 15:14:26.914 7052 7052 E AndroidRuntime: java.lang.RuntimeException: Unable to resume activity {org.chromium.blimp/org.chromium.blimp.BlimpRendererActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void org.chromium.blimp.toolbar.Toolbar.loadUrl(java.lang.String)' on a null object reference
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3103)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3134)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2481)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void org.chromium.blimp.toolbar.Toolbar.loadUrl(java.lang.String)' on a null object reference
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at org.chromium.blimp.BlimpRendererActivity.handleUrl(BlimpRendererActivity.java:179)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at org.chromium.blimp.BlimpRendererActivity.onNewIntent(BlimpRendererActivity.java:155)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.Instrumentation.callActivityOnNewIntent(Instrumentation.java:1212)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.Instrumentation.callActivityOnNewIntent(Instrumentation.java:1224)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.deliverNewIntents(ActivityThread.java:2545)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3085)
04-06 15:14:26.914 7052 7052 E AndroidRuntime: ... 10 more
04-06 15:14:27.012 573 1809 W ActivityManager: Force finishing activity org.chromium.blimp/.BlimpRendererActivity
,
Apr 8 2016
,
Apr 8 2016
,
Apr 13 2016
,
Apr 13 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/daa11718e228d5eb00640e2716016b24d24187d0 commit daa11718e228d5eb00640e2716016b24d24187d0 Author: shaktisahu <shaktisahu@chromium.org> Date: Wed Apr 13 18:39:35 2016 Fixed a crash in blimp toolbar On a slow device, sometimes onNewIntent is triggered even before the loading of libraries is completed. In that case blimp currently crashes while trying to load an URL since toolbar is not yet initialized. Fixed the crash by adding a null check. BUG= 601226 Review URL: https://codereview.chromium.org/1875523002 Cr-Commit-Position: refs/heads/master@{#387045} [modify] https://crrev.com/daa11718e228d5eb00640e2716016b24d24187d0/blimp/client/app/android/java/src/org/chromium/blimp/BlimpRendererActivity.java
,
Apr 13 2016
,
Dec 9 2016
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by klo...@chromium.org
, Apr 8 2016Labels: -Pri-2 Pri-1
Status: Assigned (was: Untriaged)