Merge "Check if the given user is unlocked when unlock by token" into pi-dev

This commit is contained in:
TreeHugger Robot
2018-03-20 23:36:37 +00:00
committed by Android (Google) Code Review

View File

@@ -545,7 +545,7 @@ public class TrustAgentService extends Service {
*/
public final void unlockUserWithToken(long handle, byte[] token, UserHandle user) {
UserManager um = (UserManager) getSystemService(Context.USER_SERVICE);
if (um.isUserUnlocked()) {
if (um.isUserUnlocked(user)) {
Slog.i(TAG, "User already unlocked");
return;
}