jroal / a2dpvolume

Automatically exported from code.google.com/p/a2dpvolume
http://jimroal.com/slist.htm
95 stars 33 forks source link

App crashes if permissions are not granted in Marshmallow #216

Closed jroal closed 7 years ago

jroal commented 8 years ago

Marshmallow introduced changes to app permissions that allows users to deny each permissions in the app settings screen in Android. A2DP Volume does not handle this. It crashes if all permissions are not granted. Need to handle this much better. App should not crash but rather just not perform the functions that required the permissions that were not granted. I need to implement this: https://developer.android.com/training/permissions/requesting.html . Looks like a nice way to deal with this but implement this will take some work. In the mean-time, please make sure all permissions are granted. You can do this in Android settings -> apps -> A2DP Volume -> permissions and enable them all.

otolino commented 7 years ago

Hi Jim,

One easy way to workaround this issue is to set your targetSdkVersion to 22. So the install will work like the previous SDKs, but it wont crash the app after install. However, the user still has the change to "deny" the permissions after the installation, so the in-app permission check should be implemented, but you buy time avoiding the annoying crashes.

greetings.

jroal commented 7 years ago

Thanks for the tip. I actually fixed the permissions issues in 2.12.4, I think. I fat-fingered the last commit so it says 2.12.14 instead. Oops. I should fix that I guess.