Merge "Fix error prone warnings" am: 8f15a06f5a

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1863056

Change-Id: I40565a18decf956a3439d54282555f82d615a363