Chromium Code Reviews| Index: net/http/http_proxy_client_socket_pool.cc |
| =================================================================== |
| --- net/http/http_proxy_client_socket_pool.cc (revision 68026) |
| +++ net/http/http_proxy_client_socket_pool.cc (working copy) |
| @@ -13,12 +13,14 @@ |
| #include "net/base/net_errors.h" |
| #include "net/http/http_network_session.h" |
| #include "net/http/http_proxy_client_socket.h" |
| +#include "net/http/http_response_headers.h" |
| #include "net/socket/client_socket_factory.h" |
| #include "net/socket/client_socket_handle.h" |
| #include "net/socket/client_socket_pool_base.h" |
| #include "net/socket/ssl_client_socket.h" |
| #include "net/socket/ssl_client_socket_pool.h" |
| #include "net/socket/tcp_client_socket_pool.h" |
| +#include "net/spdy/spdy_http_stream.h" |
| #include "net/spdy/spdy_proxy_client_socket.h" |
| #include "net/spdy/spdy_session.h" |
| #include "net/spdy/spdy_session_pool.h" |
| @@ -252,6 +254,10 @@ |
| if (error_response_info_.cert_request_info) { |
| handle->set_ssl_error_response_info(error_response_info_); |
| handle->set_is_ssl_error(true); |
| + } else if (error_response_info_.headers) { |
| + handle->set_ssl_error_response_info(error_response_info_); |
| + handle->set_pending_https_proxy_response_socket( |
| + pending_https_proxy_response_socket_.release()); |
| } |
| } |
| @@ -317,13 +323,19 @@ |
| params_->http_auth_cache(), |
| params_->http_auth_handler_factory(), |
| params_->tunnel(), |
| - using_spdy_)); |
| + using_spdy_, |
| + params_->ssl_params() != NULL)); |
| return transport_socket_->Connect(&callback_); |
| } |
| int HttpProxyConnectJob::DoHttpProxyConnectComplete(int result) { |
| - if (result == OK || result == ERR_PROXY_AUTH_REQUESTED) |
| + if (result == OK || result == ERR_PROXY_AUTH_REQUESTED) { |
| set_socket(transport_socket_.release()); |
| + } else if (result == ERR_HTTPS_PROXY_TUNNEL_CONNECTION_RESPONSE) { |
| + error_response_info_ = *transport_socket_->GetConnectResponseInfo(); |
|
vandebo (ex-Chrome)
2010/12/14 00:30:23
Urg - it just occurred to me this connection will
Ryan Hamilton
2010/12/15 20:14:17
I'm still not sure that I understand the technical
vandebo (ex-Chrome)
2010/12/15 22:52:38
I think you've got this right. A ClientSocketHand
|
| + pending_https_proxy_response_socket_.reset(transport_socket_.release()); |
| + DCHECK(!error_response_info_.cert_request_info.get()); |
| + } |
| return result; |
| } |