| OLD | NEW |
| 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/socket/ssl_client_socket_pool.h" | 5 #include "net/socket/ssl_client_socket_pool.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
| 9 #include "base/metrics/field_trial.h" | 9 #include "base/metrics/field_trial.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 if (error_response_info_.headers.get()) { | 240 if (error_response_info_.headers.get()) { |
| 241 handle->set_pending_http_proxy_connection( | 241 handle->set_pending_http_proxy_connection( |
| 242 transport_socket_handle_.release()); | 242 transport_socket_handle_.release()); |
| 243 } | 243 } |
| 244 handle->set_ssl_error_response_info(error_response_info_); | 244 handle->set_ssl_error_response_info(error_response_info_); |
| 245 if (!connect_timing_.ssl_start.is_null()) | 245 if (!connect_timing_.ssl_start.is_null()) |
| 246 handle->set_is_ssl_error(true); | 246 handle->set_is_ssl_error(true); |
| 247 } | 247 } |
| 248 | 248 |
| 249 void SSLConnectJob::OnIOComplete(int result) { | 249 void SSLConnectJob::OnIOComplete(int result) { |
| 250 // TODO(pkasting): Remove ScopedTracker below once crbug.com/455884 is fixed. |
| 251 tracked_objects::ScopedTracker tracking_profile( |
| 252 FROM_HERE_WITH_EXPLICIT_FUNCTION("455884 SSLConnectJob::OnIOComplete")); |
| 250 int rv = DoLoop(result); | 253 int rv = DoLoop(result); |
| 251 if (rv != ERR_IO_PENDING) | 254 if (rv != ERR_IO_PENDING) |
| 252 NotifyDelegateOfCompletion(rv); // Deletes |this|. | 255 NotifyDelegateOfCompletion(rv); // Deletes |this|. |
| 253 } | 256 } |
| 254 | 257 |
| 255 int SSLConnectJob::DoLoop(int result) { | 258 int SSLConnectJob::DoLoop(int result) { |
| 256 DCHECK_NE(next_state_, STATE_NONE); | 259 DCHECK_NE(next_state_, STATE_NONE); |
| 257 | 260 |
| 258 int rv = result; | 261 int rv = result; |
| 259 do { | 262 do { |
| (...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 839 CHECK(it != messenger_map_.end()); | 842 CHECK(it != messenger_map_.end()); |
| 840 delete it->second; | 843 delete it->second; |
| 841 messenger_map_.erase(it); | 844 messenger_map_.erase(it); |
| 842 } | 845 } |
| 843 | 846 |
| 844 void SSLClientSocketPool::OnSSLConfigChanged() { | 847 void SSLClientSocketPool::OnSSLConfigChanged() { |
| 845 FlushWithError(ERR_NETWORK_CHANGED); | 848 FlushWithError(ERR_NETWORK_CHANGED); |
| 846 } | 849 } |
| 847 | 850 |
| 848 } // namespace net | 851 } // namespace net |
| OLD | NEW |