Prevent GenerateChallenge being dropped in some corner cases
Fixes: 169387113
Test: Enter face settings, enroll, leave face settings, enter
face settings, remove enrollment, re-enroll
Change-Id: I323606dea6ea92599695466bbffeb4d1541e8c85
This commit is contained in:
@@ -519,19 +519,17 @@ class Face10 implements IHwBinder.DeathRecipient {
|
||||
@NonNull String opPackageName) {
|
||||
mHandler.post(() -> {
|
||||
if (mCurrentChallengeOwner != null) {
|
||||
Slog.w(TAG, "Current challenge owner: " + mCurrentChallengeOwner
|
||||
+ ", interrupted by: " + opPackageName);
|
||||
final ClientMonitorCallbackConverter listener =
|
||||
mCurrentChallengeOwner.getListener();
|
||||
if (listener == null) {
|
||||
Slog.w(TAG, "Null listener, skip sending interruption callback");
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
listener.onChallengeInterrupted(mSensorId);
|
||||
} catch (RemoteException e) {
|
||||
Slog.e(TAG, "Unable to notify challenge interrupted", e);
|
||||
Slog.w(TAG, "Current challenge owner: " + mCurrentChallengeOwner
|
||||
+ ", listener: " + listener
|
||||
+ ", interrupted by: " + opPackageName);
|
||||
if (listener != null) {
|
||||
try {
|
||||
listener.onChallengeInterrupted(mSensorId);
|
||||
} catch (RemoteException e) {
|
||||
Slog.e(TAG, "Unable to notify challenge interrupted", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user