Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 02a82289 authored by Shawn Willden's avatar Shawn Willden
Browse files

Fix deadlock caused by sending LSKF changed notification

Bug: 326363560
Test: atest com.android.cts.devicepolicy.ManagedProfilePasswordTest#testUnlockWorkProfile_deviceWidePassword
Change-Id: I710249c1153f8758d0e250a701f6966d90a53357
parent 5174adcc
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -1875,9 +1875,10 @@ public class LockSettingsService extends ILockSettings.Stub {
        }
    }

    private void onPostPasswordChanged(LockscreenCredential newCredential, int userHandle) {
        updatePasswordHistory(newCredential, userHandle);
        mContext.getSystemService(TrustManager.class).reportEnabledTrustAgentsChanged(userHandle);
    private void onPostPasswordChanged(LockscreenCredential newCredential, int userId) {
        updatePasswordHistory(newCredential, userId);
        mContext.getSystemService(TrustManager.class).reportEnabledTrustAgentsChanged(userId);
        sendMainUserCredentialChangedNotificationIfNeeded(userId);
    }

    /**
@@ -3062,7 +3063,6 @@ public class LockSettingsService extends ILockSettings.Stub {
        setCurrentLskfBasedProtectorId(newProtectorId, userId);
        LockPatternUtils.invalidateCredentialTypeCache();
        synchronizeUnifiedChallengeForProfiles(userId, profilePasswords);
        sendMainUserCredentialChangedNotificationIfNeeded(userId);

        setUserPasswordMetrics(credential, userId);
        mUnifiedProfilePasswordCache.removePassword(userId);