StrictMode to catch implicit Direct Boot matching.
When an app starts becoming Direct Boot aware, it can be difficult to track down all the places they're implicitly relying on PackageManager filtering behavior. For example, if the current Launcher isn't Direct Boot aware, we hide it until the user is unlocked, which could confuse other Direct Boot aware apps into thinking it had been uninstalled, which could cause data loss. This change helps apps track down places where they're implicitly relying on the automatic filtering; they should instead carefully choose a combination of MATCH_DIRECT_BOOT flags to decide on the explicit matching behavior they want. To implement this, we partially migrate the updateFlags() methods out into ApplicationPackageManager, since the checking needs to happen on the client side to correctly report StrictMode violations. We don't currently mutate the flags, but we retain the naming to keep that door open in the future. Test: manual Bug: 110413274 Change-Id: Iff6feba19da81ea1b4eeb3af821c3bdfbd9bf17c
Loading
Please register or sign in to comment