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

Side by Side Diff: jingle/glue/proxy_resolving_client_socket.cc

Issue 298883011: Record errors that trigger a data reduction proxy bypass (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 6 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
« no previous file with comments | « google_apis/gcm/engine/connection_factory_impl.cc ('k') | net/http/http_response_headers.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "jingle/glue/proxy_resolving_client_socket.h" 5 #include "jingle/glue/proxy_resolving_client_socket.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/bind_helpers.h" 9 #include "base/bind_helpers.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 default: 270 default:
271 return error; 271 return error;
272 } 272 }
273 273
274 if (proxy_info_.is_https() && ssl_config_.send_client_cert) { 274 if (proxy_info_.is_https() && ssl_config_.send_client_cert) {
275 network_session_->ssl_client_auth_cache()->Remove( 275 network_session_->ssl_client_auth_cache()->Remove(
276 proxy_info_.proxy_server().host_port_pair()); 276 proxy_info_.proxy_server().host_port_pair());
277 } 277 }
278 278
279 int rv = network_session_->proxy_service()->ReconsiderProxyAfterError( 279 int rv = network_session_->proxy_service()->ReconsiderProxyAfterError(
280 proxy_url_, &proxy_info_, proxy_resolve_callback_, &pac_request_, 280 proxy_url_, error, &proxy_info_, proxy_resolve_callback_, &pac_request_,
281 bound_net_log_); 281 bound_net_log_);
282 if (rv == net::OK || rv == net::ERR_IO_PENDING) { 282 if (rv == net::OK || rv == net::ERR_IO_PENDING) {
283 CloseTransportSocket(); 283 CloseTransportSocket();
284 } else { 284 } else {
285 // If ReconsiderProxyAfterError() failed synchronously, it means 285 // If ReconsiderProxyAfterError() failed synchronously, it means
286 // there was nothing left to fall-back to, so fail the transaction 286 // there was nothing left to fall-back to, so fail the transaction
287 // with the last connection error we got. 287 // with the last connection error we got.
288 rv = error; 288 rv = error;
289 } 289 }
290 290
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 return false; 396 return false;
397 } 397 }
398 398
399 void ProxyResolvingClientSocket::CloseTransportSocket() { 399 void ProxyResolvingClientSocket::CloseTransportSocket() {
400 if (transport_.get() && transport_->socket()) 400 if (transport_.get() && transport_->socket())
401 transport_->socket()->Disconnect(); 401 transport_->socket()->Disconnect();
402 transport_.reset(); 402 transport_.reset();
403 } 403 }
404 404
405 } // namespace jingle_glue 405 } // namespace jingle_glue
OLDNEW
« no previous file with comments | « google_apis/gcm/engine/connection_factory_impl.cc ('k') | net/http/http_response_headers.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698