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

Side by Side Diff: components/captive_portal/captive_portal_detector.cc

Issue 786423002: Get rid of net::DO_NOT_PROMPT_FOR_LOGIN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: delete flag from iOS code Created 5 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/captive_portal/captive_portal_detector.h" 5 #include "components/captive_portal/captive_portal_detector.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "net/base/load_flags.h" 9 #include "net/base/load_flags.h"
10 #include "net/http/http_response_headers.h" 10 #include "net/http/http_response_headers.h"
(...skipping 27 matching lines...) Expand all
38 url, 38 url,
39 net::URLFetcher::GET, 39 net::URLFetcher::GET,
40 this)); 40 this));
41 url_fetcher_->SetAutomaticallyRetryOn5xx(false); 41 url_fetcher_->SetAutomaticallyRetryOn5xx(false);
42 url_fetcher_->SetRequestContext(request_context_.get()); 42 url_fetcher_->SetRequestContext(request_context_.get());
43 43
44 // Can't safely use net::LOAD_DISABLE_CERT_REVOCATION_CHECKING here, 44 // Can't safely use net::LOAD_DISABLE_CERT_REVOCATION_CHECKING here,
45 // since then the connection may be reused without checking the cert. 45 // since then the connection may be reused without checking the cert.
46 url_fetcher_->SetLoadFlags( 46 url_fetcher_->SetLoadFlags(
47 net::LOAD_BYPASS_CACHE | 47 net::LOAD_BYPASS_CACHE |
48 net::LOAD_DO_NOT_PROMPT_FOR_LOGIN |
49 net::LOAD_DO_NOT_SAVE_COOKIES | 48 net::LOAD_DO_NOT_SAVE_COOKIES |
50 net::LOAD_DO_NOT_SEND_COOKIES | 49 net::LOAD_DO_NOT_SEND_COOKIES |
51 net::LOAD_DO_NOT_SEND_AUTH_DATA); 50 net::LOAD_DO_NOT_SEND_AUTH_DATA);
52 url_fetcher_->Start(); 51 url_fetcher_->Start();
53 } 52 }
54 53
55 void CaptivePortalDetector::Cancel() { 54 void CaptivePortalDetector::Cancel() {
56 url_fetcher_.reset(); 55 url_fetcher_.reset();
57 detection_callback_.Reset(); 56 detection_callback_.Reset();
58 } 57 }
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 return base::Time::Now(); 136 return base::Time::Now();
138 else 137 else
139 return time_for_testing_; 138 return time_for_testing_;
140 } 139 }
141 140
142 bool CaptivePortalDetector::FetchingURL() const { 141 bool CaptivePortalDetector::FetchingURL() const {
143 return url_fetcher_.get() != NULL; 142 return url_fetcher_.get() != NULL;
144 } 143 }
145 144
146 } // namespace captive_portal 145 } // namespace captive_portal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698