2
0
mirror of https://gitlab.com/Nanolx/NanoDroid synced 2024-11-09 19:10:30 +00:00

Android 10: work-around no prompt for android.permission.WRITE_EXTERNAL_STORAGE being shown

This commit is contained in:
Christopher Roy Bratusek 2019-10-13 22:35:45 +02:00
parent 0fd23b3021
commit e1110af0da

View File

@ -415,6 +415,15 @@ nanodroid_finalize () {
;;
esac
# required on Android 10, else all apps bundled with NanoDroid will not show a permission prompt for
# android.permission.WRITE_EXTERNAL_STORAGE (for whatever reason).
if [ "${SDK_VERSION}" -ge 29 ]; then
find /data/system/users -type f -name 'runtime-permissions.xml' 2>/dev/null | while read file; do
rm -f "${file}"
echo " ++ resetting permissions: ${file}"
done
fi
if [ "${MODE}" = "MAGISK" ]; then
magisk_install_finish
else