summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--services/core/java/com/android/server/biometrics/face/FaceService.java23
1 files changed, 13 insertions, 10 deletions
diff --git a/services/core/java/com/android/server/biometrics/face/FaceService.java b/services/core/java/com/android/server/biometrics/face/FaceService.java
index 9d51abeed114..a7065216f6a3 100644
--- a/services/core/java/com/android/server/biometrics/face/FaceService.java
+++ b/services/core/java/com/android/server/biometrics/face/FaceService.java
@@ -344,16 +344,19 @@ public class FaceService extends BiometricServiceBase {
@Override // Binder call
public int revokeChallenge(IBinder token) {
checkPermission(MANAGE_BIOMETRIC);
- // TODO(b/137106905): Schedule binder calls in FaceService to avoid deadlocks.
- if (getCurrentClient() == null) {
- // if we aren't handling any other HIDL calls (mCurrentClient == null), revoke the
- // challenge right away.
- return startRevokeChallenge(token);
- } else {
- // postpone revoking the challenge until we finish processing the current HIDL call.
- mRevokeChallengePending = true;
- return Status.OK;
- }
+ mHandler.post(() -> {
+ // TODO(b/137106905): Schedule binder calls in FaceService to avoid deadlocks.
+ if (getCurrentClient() == null) {
+ // if we aren't handling any other HIDL calls (mCurrentClient == null), revoke
+ // the challenge right away.
+ startRevokeChallenge(token);
+ } else {
+ // postpone revoking the challenge until we finish processing the current HIDL
+ // call.
+ mRevokeChallengePending = true;
+ }
+ });
+ return Status.OK;
}
@Override // Binder call