From 2a376723aee257f6109c0bff5d83e8ae26242242 Mon Sep 17 00:00:00 2001 From: Fan Zhang Date: Thu, 2 Mar 2017 14:27:07 -0800 Subject: [PATCH] Fix a NPE when clicking encryption interstitial header Pref tree handler cannot assume preference has non-null key. Change-Id: I790e75f3b4c888e2a48b297bea89cda0b8dbaabd Fix: 35855587 Test: runtest --path tests/app/src/com/android/settings/EncryptionInterstitialTest.java --- res/layout/encryption_interstitial_header.xml | 4 +- .../settings/EncryptionInterstitial.java | 3 ++ .../settings/EncryptionInterstitialTest.java | 53 +++++++++++++++++++ 3 files changed, 59 insertions(+), 1 deletion(-) create mode 100644 tests/app/src/com/android/settings/EncryptionInterstitialTest.java diff --git a/res/layout/encryption_interstitial_header.xml b/res/layout/encryption_interstitial_header.xml index 9601fa874c1..b4f6dbb3946 100644 --- a/res/layout/encryption_interstitial_header.xml +++ b/res/layout/encryption_interstitial_header.xml @@ -15,7 +15,9 @@ limitations under the License. --> -