| 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/spdy/spdy_session_pool.h" | 5 #include "net/spdy/spdy_session_pool.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/metrics/histogram_macros.h" | 8 #include "base/metrics/histogram_macros.h" |
| 9 #include "base/profiler/scoped_tracker.h" | 9 #include "base/profiler/scoped_tracker.h" |
| 10 #include "base/values.h" | 10 #include "base/values.h" |
| 11 #include "net/base/address_list.h" | 11 #include "net/base/address_list.h" |
| 12 #include "net/http/http_network_session.h" | 12 #include "net/http/http_network_session.h" |
| 13 #include "net/http/http_server_properties.h" | 13 #include "net/http/http_server_properties.h" |
| 14 #include "net/spdy/spdy_session.h" | 14 #include "net/spdy/spdy_session.h" |
| 15 | 15 |
| 16 | |
| 17 namespace net { | 16 namespace net { |
| 18 | 17 |
| 19 namespace { | 18 namespace { |
| 20 | 19 |
| 21 enum SpdySessionGetTypes { | 20 enum SpdySessionGetTypes { |
| 22 CREATED_NEW = 0, | 21 CREATED_NEW = 0, |
| 23 FOUND_EXISTING = 1, | 22 FOUND_EXISTING = 1, |
| 24 FOUND_EXISTING_FROM_IP_POOL = 2, | 23 FOUND_EXISTING_FROM_IP_POOL = 2, |
| 25 IMPORTED_FROM_SOCKET = 3, | 24 IMPORTED_FROM_SOCKET = 3, |
| 26 SPDY_SESSION_GET_MAX = 4 | 25 SPDY_SESSION_GET_MAX = 4 |
| (...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 370 | 369 |
| 371 if (idle_only && (*it)->is_active()) | 370 if (idle_only && (*it)->is_active()) |
| 372 continue; | 371 continue; |
| 373 | 372 |
| 374 (*it)->CloseSessionOnError(error, description); | 373 (*it)->CloseSessionOnError(error, description); |
| 375 DCHECK(!IsSessionAvailable(*it)); | 374 DCHECK(!IsSessionAvailable(*it)); |
| 376 } | 375 } |
| 377 } | 376 } |
| 378 | 377 |
| 379 } // namespace net | 378 } // namespace net |
| OLD | NEW |