Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4098)

Unified Diff: chrome/browser/signin/signin_manager.cc

Issue 12817005: Allow encoded version of service=chromiumsync (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Decode the URL instead of searching for two versions of the string Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/signin/signin_manager.cc
diff --git a/chrome/browser/signin/signin_manager.cc b/chrome/browser/signin/signin_manager.cc
index 2d033d0a5aeed995047a2869c3446b1195c8f315..18a41dfd68bc512be87a0316bceef751cc661da5 100644
--- a/chrome/browser/signin/signin_manager.cc
+++ b/chrome/browser/signin/signin_manager.cc
@@ -43,6 +43,7 @@
#include "google_apis/gaia/gaia_auth_util.h"
#include "google_apis/gaia/gaia_constants.h"
#include "google_apis/gaia/gaia_urls.h"
+#include "net/base/escape.h"
#include "net/url_request/url_request_context.h"
#include "third_party/icu/public/i18n/unicode/regex.h"
@@ -87,8 +88,10 @@ bool SigninManager::IsWebBasedSigninFlowURL(const GURL& url) {
// Any login UI URLs with signin=chromiumsync should be considered a web
// URL (relies on GAIA keeping the "service=chromiumsync" query string
- // fragment intact even when embedding inside a "continue" parameter).
- return url.query().find(kChromiumSyncService) != std::string::npos;
+ // fragment present even when embedding inside a "continue" parameter).
+ return net::UnescapeURLComponent(
+ url.query(), net::UnescapeRule::URL_SPECIAL_CHARS)
+ .find(kChromiumSyncService) != std::string::npos;
}
// static
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698