diff options
| author | 2022-11-16 11:05:58 -0800 | |
|---|---|---|
| committer | 2022-11-16 13:43:06 -0800 | |
| commit | 3dc5a4b1bbe88d5ec8fe30cff19aadeb401c9d78 (patch) | |
| tree | 738afcbe9985945cc3107640a8550c6bcadb421e /libs/androidfw/Util.cpp | |
| parent | c68b02a3b29e73faaf86544ea05674fc2730598c (diff) | |
Stop using CannotDeliverBroadcastException
This crash behavior was introduced a long time ago to show a crash
dialog if the broadcast couldn't be delivered (b/28196243). Android
has changed a lot since then. The crash dialog won't be shown to the
user as it impacts user experience, especially when the app is in the
background.
Furthermore, this CannotDeliverBroadcastException crashes the app with
the same callstack, without any useful information for app developers
to debug the issue. And it pollutes the app crashlytics stats in a
negative way so app developers choose to suppress it (b/245258072).
This exception is hidden and not documented at developers.android.com.
Let's stop sending it to apps. Kill the app gently instead (as what's
already mentioned in the comments).
Bug: 239419108
Test: atest BroadcastQueueTest
Test: observe app is killed gently on failed broadcast (instead of crash)
Change-Id: I93aabe99167105111f9f3bd945cf4977cfb8cdb1
Diffstat (limited to 'libs/androidfw/Util.cpp')
0 files changed, 0 insertions, 0 deletions