katit
katit

Reputation: 17915

Android crash on resume. How to interpret this exception?

I got couple of crash reports like this one and I'm not sure what does it mean. Just to make it clear - this is something I can't reproduce. This is reported by ACRA

'Unmarshalling unknown type code 2131296357 at offset 1232'

Full error stack trace below:

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.idatt/com.idatt.activities.NewMailActivity}: java.lang.RuntimeException: Parcel android.os.Parcel@40651010: Unmarshalling unknown type code 2131296357 at offset 1232
 at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1651)
 at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1667)
 at android.app.ActivityThread.access$1500(ActivityThread.java:117)
 at android.app.ActivityThread$H.handleMessage(ActivityThread.java:935)
 at android.os.Handler.dispatchMessage(Handler.java:99)
 at android.os.Looper.loop(Looper.java:130)
 at android.app.ActivityThread.main(ActivityThread.java:3687)
 at java.lang.reflect.Method.invokeNative(Native Method)
 at java.lang.reflect.Method.invoke(Method.java:507)
 at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842)
 at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
 at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.RuntimeException: Parcel android.os.Parcel@40651010: Unmarshalling unknown type code 2131296357 at offset 1232
 at android.os.Parcel.readValue(Parcel.java:1913)
 at android.os.Parcel.readSparseArrayInternal(Parcel.java:2112)
 at android.os.Parcel.readSparseArray(Parcel.java:1568)
 at android.os.Parcel.readValue(Parcel.java:1903)
 at android.os.Parcel.readMapInternal(Parcel.java:2083)
 at android.os.Bundle.unparcel(Bundle.java:208)
 at android.os.Bundle.getSparseParcelableArray(Bundle.java:1167)
 at com.android.internal.policy.impl.PhoneWindow.restoreHierarchyState(PhoneWindow.java:1682)
 at android.app.Activity.onRestoreInstanceState(Activity.java:844)
 at android.app.Activity.performRestoreInstanceState(Activity.java:816)
 at android.app.Instrumentation.callActivityOnRestoreInstanceState(Instrumentation.java:1096)
 at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1629)
 ... 11 more
java.lang.RuntimeException: Parcel android.os.Parcel@40651010: Unmarshalling unknown type code 2131296357 at offset 1232
 at android.os.Parcel.readValue(Parcel.java:1913)
 at android.os.Parcel.readSparseArrayInternal(Parcel.java:2112)
 at android.os.Parcel.readSparseArray(Parcel.java:1568)
 at android.os.Parcel.readValue(Parcel.java:1903)
 at android.os.Parcel.readMapInternal(Parcel.java:2083)
 at android.os.Bundle.unparcel(Bundle.java:208)
 at android.os.Bundle.getSparseParcelableArray(Bundle.java:1167)
 at com.android.internal.policy.impl.PhoneWindow.restoreHierarchyState(PhoneWindow.java:1682)
 at android.app.Activity.onRestoreInstanceState(Activity.java:844)
 at android.app.Activity.performRestoreInstanceState(Activity.java:816)
 at android.app.Instrumentation.callActivityOnRestoreInstanceState(Instrumentation.java:1096)
 at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1629)
 at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1667)
 at android.app.ActivityThread.access$1500(ActivityThread.java:117)
 at android.app.ActivityThread$H.handleMessage(ActivityThread.java:935)
 at android.os.Handler.dispatchMessage(Handler.java:99)
 at android.os.Looper.loop(Looper.java:130)
 at android.app.ActivityThread.main(ActivityThread.java:3687)
 at java.lang.reflect.Method.invokeNative(Native Method)
 at java.lang.reflect.Method.invoke(Method.java:507)
 at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842)
 at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
 at dalvik.system.NativeStart.main(Native Method)

Upvotes: 8

Views: 2256

Answers (1)

Brian Cooley
Brian Cooley

Reputation: 11662

On the emulator, there should be a Dev Tools app. Open that app, select "Development Settings" from the list, and check the box next to "Immediately destroy activities". Now, when you run your app, when you hit the home button, the foreground Activity will be destroyed. You can then restart your app via long press or from the Apps screen to recreate the bug.

Upvotes: 6

Related Questions