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

Commit c77de1f0 authored by Dmitry Dementyev's avatar Dmitry Dementyev Committed by Android (Google) Code Review
Browse files

Merge "Check account type returned by AbstractAccountAuthenticator." into sc-dev

parents 9500429c fb41e444
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -3070,6 +3070,12 @@ public class AccountManagerService
                                        "the type and name should not be empty");
                                return;
                            }
                            if (!type.equals(mAccountType)) {
                                onError(AccountManager.ERROR_CODE_INVALID_RESPONSE,
                                        "incorrect account type");
                                return;
                            }

                            Account resultAccount = new Account(name, type);
                            if (!customTokens) {
                                saveAuthTokenToDatabase(