summaryrefslogtreecommitdiff
path: root/libs/androidfw/FileStream.cpp
diff options
context:
space:
mode:
author Martijn Coenen <maco@google.com> 2023-10-28 20:52:52 +0000
committer Martijn Coenen <maco@google.com> 2023-10-30 18:10:06 +0000
commite6f64527c1ad6fa8f01e89e482b72ba8d8b84f5b (patch)
tree24230d716f89e6f908a74ef3da6e06ec63d3e454 /libs/androidfw/FileStream.cpp
parentf57ecad0402ddbe19f35c125b67b7441eb01716b (diff)
Zygote: do not fail if CE app data dir not found.
When app data isolation is enabled, Zygote assumes that the CE directories are there. Indeed this is normally always the case; on first boot, the directories for the pre-installed apps are created by the PackageManager. For newly installed applications, PackageManager will make sure the CE dirs are created. However, it is possible for the device to get into a state where these directories are deleted, even for pre-installed apps. In that case, the device will now refuse to boot, because critical system apps like SystemUI cannot fork from Zygote as its CE data dir is missing. Change the failure to a warning, which will allow devices to boot in such cases. This effectively means that for the current boot, app data isolation for CE directories will not be active. The directories will get created later, and subsequently app data isolation will work again on the next boot. Currently the only way we know how to get in this situation is through a case where user data cannot be 'prepared', and we trash all user data. In such a case, there are no 3rd party apps installed, and any apps that will be installed in the boot cycle will have functioning app data isolation from the start. Bug: 305658663 Test: Manual Change-Id: I04d701cf03352c23bc7fd6dc99f181cb1ed8d804
Diffstat (limited to 'libs/androidfw/FileStream.cpp')
0 files changed, 0 insertions, 0 deletions