Skip to content
Commit 09e4403d authored by Hai Zhang's avatar Hai Zhang
Browse files

Read permission state before scanning packages.

The readLegacyPermissionStateTEMP() call was originally introduced right
before the old updateAllPermissions() call in ag/12329540 probably
because we wanted to make sure packages have been properly scanned and
reconciled before permission code tries to read permission state in
combination with the existing package settings. But in the case of OTA
removing a system app, it is possible for the permission state to change
during the package reconciliation so the permission state should indeed
be read earlier. It should actually be fine to read the permission state
earlier as well because in
Settings.RuntimePermissionPersistence.readStateForUserSyncLPr() (part of
Settings.readLPw()), we are also consulting the not-yet-reconciled
package settings and that has been fine for a long time.

Fixes: 196177583
Test: presubmit
Change-Id: I01dae1da934f927ca87b62773b6673a9b3aefb8a
parent abd75290
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment