Fix NullPointerException when renaming a fingerprint
(Original change made by xingbin.feng@sony.com) Fix NullPointerException when rotating the screen while renaming a registered fingerprint Bug: 236873593 Test: Click a registered fingerprint to open the Rename dialog, rotate the device and press OK. Verify that Settings does not crash Change-Id: I1350c4bd121e0a7aaa291b3b8f96c80ef777150b
This commit is contained in:
@@ -906,8 +906,10 @@ public class FingerprintSettings extends SubSettings {
|
||||
@Override
|
||||
public void onCancel(DialogInterface dialog) {
|
||||
super.onCancel(dialog);
|
||||
if (mDismissListener != null) {
|
||||
mDismissListener.onDismiss(dialog);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public Dialog onCreateDialog(Bundle savedInstanceState) {
|
||||
@@ -944,7 +946,9 @@ public class FingerprintSettings extends SubSettings {
|
||||
parent.renameFingerPrint(mFp.getBiometricId(),
|
||||
newName);
|
||||
}
|
||||
if (mDismissListener != null) {
|
||||
mDismissListener.onDismiss(dialog);
|
||||
}
|
||||
dialog.dismiss();
|
||||
}
|
||||
})
|
||||
|
Reference in New Issue
Block a user