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

Unified Diff: net/http/http_auth_cache.cc

Issue 10916272: Remove HttpAuth::Scheme enum in favor of a string. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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 | « net/http/http_auth_cache.h ('k') | net/http/http_auth_cache_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_auth_cache.cc
diff --git a/net/http/http_auth_cache.cc b/net/http/http_auth_cache.cc
index 2cc2c0ce556249576f52b298efe7536753b1bca1..43ce7d660bf14c5105717edb4e94c5cfdd733cdc 100644
--- a/net/http/http_auth_cache.cc
+++ b/net/http/http_auth_cache.cc
@@ -68,7 +68,7 @@ HttpAuthCache::~HttpAuthCache() {
// Performance: O(n), where n is the number of realm entries.
HttpAuthCache::Entry* HttpAuthCache::Lookup(const GURL& origin,
const std::string& realm,
- HttpAuth::Scheme scheme) {
+ const std::string& scheme) {
CheckOriginIsValid(origin);
// Linear scan through the realm entries.
@@ -110,7 +110,7 @@ HttpAuthCache::Entry* HttpAuthCache::LookupByPath(const GURL& origin,
HttpAuthCache::Entry* HttpAuthCache::Add(const GURL& origin,
const std::string& realm,
- HttpAuth::Scheme scheme,
+ const std::string& scheme,
const std::string& auth_challenge,
const AuthCredentials& credentials,
const std::string& path) {
@@ -154,8 +154,7 @@ void HttpAuthCache::Entry::UpdateStaleChallenge(
}
HttpAuthCache::Entry::Entry()
- : scheme_(HttpAuth::AUTH_SCHEME_MAX),
- nonce_count_(0) {
+ : nonce_count_(0) {
}
void HttpAuthCache::Entry::AddPath(const std::string& path) {
@@ -196,7 +195,7 @@ bool HttpAuthCache::Entry::HasEnclosingPath(const std::string& dir,
bool HttpAuthCache::Remove(const GURL& origin,
const std::string& realm,
- HttpAuth::Scheme scheme,
+ const std::string& scheme,
const AuthCredentials& credentials) {
for (EntryList::iterator it = entries_.begin(); it != entries_.end(); ++it) {
if (it->origin() == origin && it->realm() == realm &&
@@ -213,7 +212,7 @@ bool HttpAuthCache::Remove(const GURL& origin,
bool HttpAuthCache::UpdateStaleChallenge(const GURL& origin,
const std::string& realm,
- HttpAuth::Scheme scheme,
+ const std::string& scheme,
const std::string& auth_challenge) {
HttpAuthCache::Entry* entry = Lookup(origin, realm, scheme);
if (!entry)
« no previous file with comments | « net/http/http_auth_cache.h ('k') | net/http/http_auth_cache_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698