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

Side by Side Diff: net/base/network_delegate.cc

Issue 473513002: Keep track of network error in ProxyRetryInfo. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge to head. Created 6 years, 4 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 "net/base/network_delegate.h" 5 #include "net/base/network_delegate.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "net/base/load_flags.h" 8 #include "net/base/load_flags.h"
9 #include "net/base/net_errors.h" 9 #include "net/base/net_errors.h"
10 #include "net/proxy/proxy_info.h" 10 #include "net/proxy/proxy_info.h"
(...skipping 15 matching lines...) Expand all
26 int load_flags, 26 int load_flags,
27 const ProxyService& proxy_service, 27 const ProxyService& proxy_service,
28 ProxyInfo* result) { 28 ProxyInfo* result) {
29 DCHECK(CalledOnValidThread()); 29 DCHECK(CalledOnValidThread());
30 DCHECK(result); 30 DCHECK(result);
31 OnResolveProxy(url, load_flags, proxy_service, result); 31 OnResolveProxy(url, load_flags, proxy_service, result);
32 } 32 }
33 33
34 void NetworkDelegate::NotifyProxyFallback( 34 void NetworkDelegate::NotifyProxyFallback(
35 const ProxyServer& bad_proxy, 35 const ProxyServer& bad_proxy,
36 int net_error, 36 int net_error) {
37 bool did_fallback) {
38 DCHECK(CalledOnValidThread()); 37 DCHECK(CalledOnValidThread());
39 OnProxyFallback(bad_proxy, net_error, did_fallback); 38 OnProxyFallback(bad_proxy, net_error);
40 } 39 }
41 40
42 int NetworkDelegate::NotifyBeforeSendHeaders( 41 int NetworkDelegate::NotifyBeforeSendHeaders(
43 URLRequest* request, const CompletionCallback& callback, 42 URLRequest* request, const CompletionCallback& callback,
44 HttpRequestHeaders* headers) { 43 HttpRequestHeaders* headers) {
45 DCHECK(CalledOnValidThread()); 44 DCHECK(CalledOnValidThread());
46 DCHECK(headers); 45 DCHECK(headers);
47 DCHECK(!callback.is_null()); 46 DCHECK(!callback.is_null());
48 return OnBeforeSendHeaders(request, callback, headers); 47 return OnBeforeSendHeaders(request, callback, headers);
49 } 48 }
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 } 173 }
175 174
176 void NetworkDelegate::OnResolveProxy( 175 void NetworkDelegate::OnResolveProxy(
177 const GURL& url, 176 const GURL& url,
178 int load_flags, 177 int load_flags,
179 const ProxyService& proxy_service, 178 const ProxyService& proxy_service,
180 ProxyInfo* result) { 179 ProxyInfo* result) {
181 } 180 }
182 181
183 void NetworkDelegate::OnProxyFallback(const ProxyServer& bad_proxy, 182 void NetworkDelegate::OnProxyFallback(const ProxyServer& bad_proxy,
184 int net_error, 183 int net_error) {
185 bool did_fallback) {
186 } 184 }
187 185
188 int NetworkDelegate::OnBeforeSendHeaders(URLRequest* request, 186 int NetworkDelegate::OnBeforeSendHeaders(URLRequest* request,
189 const CompletionCallback& callback, 187 const CompletionCallback& callback,
190 HttpRequestHeaders* headers) { 188 HttpRequestHeaders* headers) {
191 return OK; 189 return OK;
192 } 190 }
193 191
194 void NetworkDelegate::OnBeforeSendProxyHeaders( 192 void NetworkDelegate::OnBeforeSendProxyHeaders(
195 URLRequest* request, 193 URLRequest* request,
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 return false; 263 return false;
266 } 264 }
267 265
268 int NetworkDelegate::OnBeforeSocketStreamConnect( 266 int NetworkDelegate::OnBeforeSocketStreamConnect(
269 SocketStream* socket, 267 SocketStream* socket,
270 const CompletionCallback& callback) { 268 const CompletionCallback& callback) {
271 return OK; 269 return OK;
272 } 270 }
273 271
274 } // namespace net 272 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698