Loading services/core/java/com/android/server/locksettings/LockSettingsService.java +11 −5 Original line number Diff line number Diff line Loading @@ -955,13 +955,19 @@ public class LockSettingsService extends ILockSettings.Stub { @GuardedBy("mSeparateChallengeLock") private void setSeparateProfileChallengeEnabledLocked(@UserIdInt int userId, boolean enabled, String managedUserPassword) { final boolean old = getBoolean(SEPARATE_PROFILE_CHALLENGE_KEY, false, userId); setBoolean(SEPARATE_PROFILE_CHALLENGE_KEY, enabled, userId); try { if (enabled) { mStorage.removeChildProfileLock(userId); removeKeystoreProfileKey(userId); } else { tieManagedProfileLockIfNecessary(userId, managedUserPassword); } } catch (IllegalStateException e) { setBoolean(SEPARATE_PROFILE_CHALLENGE_KEY, old, userId); throw e; } } private void notifySeparateProfileChallengeChanged(int userId) { Loading Loading
services/core/java/com/android/server/locksettings/LockSettingsService.java +11 −5 Original line number Diff line number Diff line Loading @@ -955,13 +955,19 @@ public class LockSettingsService extends ILockSettings.Stub { @GuardedBy("mSeparateChallengeLock") private void setSeparateProfileChallengeEnabledLocked(@UserIdInt int userId, boolean enabled, String managedUserPassword) { final boolean old = getBoolean(SEPARATE_PROFILE_CHALLENGE_KEY, false, userId); setBoolean(SEPARATE_PROFILE_CHALLENGE_KEY, enabled, userId); try { if (enabled) { mStorage.removeChildProfileLock(userId); removeKeystoreProfileKey(userId); } else { tieManagedProfileLockIfNecessary(userId, managedUserPassword); } } catch (IllegalStateException e) { setBoolean(SEPARATE_PROFILE_CHALLENGE_KEY, old, userId); throw e; } } private void notifySeparateProfileChallengeChanged(int userId) { Loading