OSDN Git Service

Make SuggestionController guard RuntimeException.
authorZhizhi Liu <zhizhiliu@google.com>
Thu, 22 Feb 2018 23:33:42 +0000 (15:33 -0800)
committerZhizhi Liu <zhizhiliu@google.com>
Thu, 22 Feb 2018 23:33:42 +0000 (15:33 -0800)
commitdf74a5b16fbc7ab7553bc520cc46a9879b65543a
tree7f227fcd6ac939342e5878366b9775721fd67d93
parentf658bd75fbc5d8e73c9202801d51da86b4536842
Make SuggestionController guard RuntimeException.

The crash happens when SettingsIntelligence throws
IllegalArgumentException(it is handled in the other CL).
To make sure SuggestionController are not influenced by this kind of
exceptions and thus propagate to TvSettings, do a double check here.

b/72644591

Test: By using a wrong uri for suggested settings, it won't crash
TvSettings.

Change-Id: I3b4d4630f3630c046320f8f4b9c5e0032907976d
packages/SettingsLib/src/com/android/settingslib/suggestions/SuggestionController.java