Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Android] Storage Manager: Try fallback to obtain drives if running on Android 6 and older #19803

Merged
merged 1 commit into from
May 25, 2021

Conversation

ksooo
Copy link
Member

@ksooo ksooo commented May 25, 2021

Only use https://developer.android.com/reference/android/os/storage/StorageManager#getStorageVolumes() if running on a device with at least SDK level 24. Otherwise use fallback via /proc/mounts.

Fixes a regression introduced by #19523.

@koying does this look sane?

@ksooo ksooo added Type: Fix non-breaking change which fixes an issue Backport: Needed Platform: Android v20 Nexus labels May 25, 2021
@ksooo ksooo added this to the N* 20.0 Alpha 1 milestone May 25, 2021
@koying
Copy link
Contributor

koying commented May 25, 2021

I'm surprised the fallback doesn't happen in the current version, tbh.
But yeah, if this fixes a regression, it's good.

@ksooo
Copy link
Member Author

ksooo commented May 25, 2021

I'm surprised the fallback doesn't happen in the current version, tbh.

I messed it up with xbmc/libandroidjni#23
Since then, libandroidjni does no longer throw an exception when running on < 24, thus the fallback was not used any longer.

@koying
Copy link
Contributor

koying commented May 25, 2021

Ah, right :)

…n Android 6 and older (SDK API level < 24) or in case of error.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backport: Done Platform: Android Type: Fix non-breaking change which fixes an issue v20 Nexus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants