3
votes

I'm using in my app several libraries from android support and i update them when they are available.

During the test of the version 23.2.0, i've got a crash when i change the app permissions on android 6. As you know, when the user disable a permission, the app is recreated (same way as when the device rotate) and your parcelable objects are saved and restored from a bundle.

With the version 23.2.0, when the app is recreated, i've got a parcel error. I think that this error is not from my code but from the android code. I don't have this error when i use the libraries version 23.1.1 or lower.

Here is a dump :

E/AndroidRuntime: FATAL EXCEPTION: main Process: org.team.acs.scubalog, PID: 15378 java.lang.RuntimeException: Unable to start activity ComponentInfo{org.team.acs.scubalog/org.team.acs.scubalog.MainActivity}: java.lang.RuntimeException: Parcel android.os.Parcel@3a99bef: Unmarshalling unknown type code 3801188 at offset 2452 at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476) at android.app.ActivityThread.-wrap11(ActivityThread.java) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:148) at android.app.ActivityThread.main(ActivityThread.java:5417) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) Caused by: java.lang.RuntimeException: Parcel android.os.Parcel@3a99bef: Unmarshalling unknown type code 3801188 at offset 2452 at android.os.Parcel.readValue(Parcel.java:2340) at android.os.Parcel.readArrayMapInternal(Parcel.java:2614) at android.os.BaseBundle.unparcel(BaseBundle.java:221) at android.os.Bundle.getSparseParcelableArray(Bundle.java:856) at com.android.internal.policy.PhoneWindow.restoreHierarchyState(PhoneWindow.java:2033) at android.app.Activity.onRestoreInstanceState(Activity.java:1008) at android.app.Activity.performRestoreInstanceState(Activity.java:963) at android.app.Instrumentation.callActivityOnRestoreInstanceState(Instrumentation.java:1163) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2389) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)  at android.app.ActivityThread.-wrap11(ActivityThread.java)  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)  at android.os.Handler.dispatchMessage(Handler.java:102)  at android.os.Looper.loop(Looper.java:148)  at android.app.ActivityThread.main(ActivityThread.java:5417)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) 

After investigation, the libraries which produce this error are

com.android.support:appcompat-v7:23.2.0 AND com.android.support:design:23.2.0

If i use the version 23.1.1 => no crash.

Any idea about this crash ?

1
sasikumar : Which part of my code do you want ? ;) unfortunately, i don't know where investigate... :/acs-team
IntelliJ Amiya : I already saw this post. The crash is different. My app works very well except when i change the permission on android 6 and higher. In the post they speak about a crash in the api 17 and not 22. In my case it crash only with the api 23.acs-team
@acs-team: I got a similar (maybe?) issue and posted it here: stackoverflow.com/questions/35652481/….henrykodev
Thanks guys !!! Just wait the version 23.2.1 ! ;)acs-team

1 Answers

0
votes

Bug is fixed on support library 23.2.1

Ref: App with SearchView crashing on restore