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/dns/dns_socket_pool.h" | 5 #include "net/dns/dns_socket_pool.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/macros.h" |
8 #include "base/rand_util.h" | 9 #include "base/rand_util.h" |
9 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
10 #include "net/base/address_list.h" | 11 #include "net/base/address_list.h" |
11 #include "net/base/ip_endpoint.h" | 12 #include "net/base/ip_endpoint.h" |
12 #include "net/base/net_errors.h" | 13 #include "net/base/net_errors.h" |
13 #include "net/base/rand_callback.h" | 14 #include "net/base/rand_callback.h" |
14 #include "net/socket/client_socket_factory.h" | 15 #include "net/socket/client_socket_factory.h" |
15 #include "net/socket/stream_socket.h" | 16 #include "net/socket/stream_socket.h" |
16 #include "net/udp/datagram_client_socket.h" | 17 #include "net/udp/datagram_client_socket.h" |
17 | 18 |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
208 for (unsigned pool_index = pool.size(); pool_index < size; ++pool_index) { | 209 for (unsigned pool_index = pool.size(); pool_index < size; ++pool_index) { |
209 DatagramClientSocket* socket = | 210 DatagramClientSocket* socket = |
210 CreateConnectedSocket(server_index).release(); | 211 CreateConnectedSocket(server_index).release(); |
211 if (!socket) | 212 if (!socket) |
212 break; | 213 break; |
213 pool.push_back(socket); | 214 pool.push_back(socket); |
214 } | 215 } |
215 } | 216 } |
216 | 217 |
217 } // namespace net | 218 } // namespace net |
OLD | NEW |