Update UserState for the user created during installation
When the installation is only for a specific user, as opposed to USER_ALL: 1. If the pkg is installed for the first time, and at the same time a new user is being created, there will be no UserState for the newer user. It will be created and will reset uninstall reason in the updateSettingsInternalLI(). The default value of installed is ture. It is wrong, the pkg should not be installed to the new user. To fix it, create UserState and set it as not installed when installation is only for a user. 2. If the pkg is not first installed, the UserState of the new user will be cleared when update all states from older package settings that is created when scanning pkg. To fix this issue, make it not clean all existing UserStates when update from old package setting. Bug: 409156628 Flag: EXEMPT bug fix Test: atest CtsPackageInstallTestCases Change-Id: I382222f8173c49e1ae68454ee113804254624b29
Loading
Please register or sign in to comment