Add a method to notify when is safe to send broadcasts
See https://source.corp.google.com/android/frameworks/base/services/core/java/com/android/server/pm/PackageInstallerService.java;rcl=45f6b4ce664df69d4f7db33f6d413a2574973121;l=286-288 It is possible for broadcasts to be rejected by AMS with an exception even if mOkToSendBroadcasts is true. This causes b/160106846 and crashes the system server which then fails staged installs as well as StagedInstallTest. Lifecycle listens to boot phases and calls #onBroadcastReady to notify that it is now safe to send broadcasts. Bug: 160106846 Test: atest StagedInstallTest Change-Id: I984167c592411a1685e9d9f714d1cb22f0bc9964
Loading
Please register or sign in to comment