Opened 5 months ago

Closed 8 weeks ago

#2389 closed defect (fixed)

Android: AbstractWizardModel bug

Reported by: Meeh Owned by: Meeh
Priority: minor Milestone: 0.9.40
Component: apps/android Version: 0.9.37
Keywords: Cc:
Parent Tickets: Sensitive: no

Description

java.lang.RuntimeException?:

at android.app.ActivityThread?.performLaunchActivity (ActivityThread?.java:2900)
at android.app.ActivityThread?.handleLaunchActivity (ActivityThread?.java:2979)
at android.app.ActivityThread?.handleRelaunchActivity (ActivityThread?.java:4868)
at android.app.ActivityThread?.-wrap18 (Unknown Source)
at android.app.ActivityThread?$H.handleMessage (ActivityThread?.java:1640)
at android.os.Handler.dispatchMessage (Handler.java:105)
at android.os.Looper.loop (Looper.java:164)
at android.app.ActivityThread?.main (ActivityThread?.java:6673)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller?.run (Zygote.java:240)
at com.android.internal.os.ZygoteInit?.main (ZygoteInit?.java:769)

Caused by: java.lang.NullPointerException?:

at net.i2p.android.wizard.model.AbstractWizardModel?.load (AbstractWizardModel?.java:70)
at net.i2p.android.wizard.ui.AbstractWizardActivity?.onCreate (AbstractWizardActivity?.java:52)
at android.app.Activity.performCreate (Activity.java:6984)
at android.app.Instrumentation.callActivityOnCreate (Instrumentation.java:1235)
at android.app.ActivityThread?.performLaunchActivity (ActivityThread?.java:2853)

Subtickets

Change History (5)

comment:1 Changed 5 months ago by zzz

Milestone: eventually0.9.38
Status: newopen

I think you could fix this by making mRootPageList final.
Looks like mListeners and mContext could be final also.

comment:2 Changed 5 months ago by Zlatin Balevsky

I'm not familiar with the threading model on Android, but I suggest we make net.i2p.android.wizard.model.PageList extend CopyOnWriteArrayList

comment:3 Changed 5 months ago by Meeh

Expanded the code and hope this happens again so we can figure out where the NPE came from.

comment:4 Changed 5 months ago by zzz

Milestone: 0.9.380.9.39

Due to a misunderstanding? My recommendation in comment 1 was not implemented for 38. Please implement it for .39.

comment:5 Changed 8 weeks ago by zzz

Milestone: 0.9.390.9.40
Resolution: fixed
Status: openclosed

finals checked in for 0.9.40 as described in comment 1

Note: See TracTickets for help on using tickets.