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

Commit dc1fc7fc authored by Adrian Roos's avatar Adrian Roos Committed by Android Git Automerger
Browse files

am 05ade73e: Merge "Ensure that setting an empty password clears it" into lmp-dev

* commit '05ade73e580b826ead839d3c5db508a8ea25ad93':
  Ensure that setting an empty password clears it
parents 3517b1db 625e8f59
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -780,9 +780,9 @@ public class LockPatternUtils {
     */
    public void saveLockPassword(String password, int quality, boolean isFallback, int userHandle) {
        try {
            getLockSettings().setLockPassword(password, userHandle);
            DevicePolicyManager dpm = getDevicePolicyManager();
            if (!TextUtils.isEmpty(password)) {
                getLockSettings().setLockPassword(password, userHandle);
                int computedQuality = computePasswordQuality(password);

                if (userHandle == UserHandle.USER_OWNER) {
@@ -860,6 +860,7 @@ public class LockPatternUtils {
                setString(PASSWORD_HISTORY_KEY, passwordHistory, userHandle);
            } else {
                // Empty password
                getLockSettings().setLockPassword(null, userHandle);
                if (userHandle == UserHandle.USER_OWNER) {
                    // Set the encryption password to default.
                    updateEncryptionPassword(StorageManager.CRYPT_TYPE_DEFAULT, null);