| 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/address_sorter_posix.h" | 5 #include "net/dns/address_sorter_posix.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "net/base/ip_address.h" | 10 #include "net/base/ip_address.h" |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 int GetPeerAddress(IPEndPoint* address) const override { | 54 int GetPeerAddress(IPEndPoint* address) const override { |
| 55 NOTIMPLEMENTED(); | 55 NOTIMPLEMENTED(); |
| 56 return OK; | 56 return OK; |
| 57 } | 57 } |
| 58 int GetLocalAddress(IPEndPoint* address) const override { | 58 int GetLocalAddress(IPEndPoint* address) const override { |
| 59 if (!connected_) | 59 if (!connected_) |
| 60 return ERR_UNEXPECTED; | 60 return ERR_UNEXPECTED; |
| 61 *address = local_endpoint_; | 61 *address = local_endpoint_; |
| 62 return OK; | 62 return OK; |
| 63 } | 63 } |
| 64 void UseNonBlockingIO() override {} | |
| 65 int ConnectUsingNetwork(NetworkChangeNotifier::NetworkHandle network, | 64 int ConnectUsingNetwork(NetworkChangeNotifier::NetworkHandle network, |
| 66 const IPEndPoint& address) override { | 65 const IPEndPoint& address) override { |
| 67 NOTIMPLEMENTED(); | 66 NOTIMPLEMENTED(); |
| 68 return ERR_NOT_IMPLEMENTED; | 67 return ERR_NOT_IMPLEMENTED; |
| 69 } | 68 } |
| 70 int ConnectUsingDefaultNetwork(const IPEndPoint& address) override { | 69 int ConnectUsingDefaultNetwork(const IPEndPoint& address) override { |
| 71 NOTIMPLEMENTED(); | 70 NOTIMPLEMENTED(); |
| 72 return ERR_NOT_IMPLEMENTED; | 71 return ERR_NOT_IMPLEMENTED; |
| 73 } | 72 } |
| 74 NetworkChangeNotifier::NetworkHandle GetBoundNetwork() const override { | 73 NetworkChangeNotifier::NetworkHandle GetBoundNetwork() const override { |
| (...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 329 AddMapping("4000::1", "4000::10"); // global unicast | 328 AddMapping("4000::1", "4000::10"); // global unicast |
| 330 AddMapping("ff32::2", "fe81::20"); // deprecated link-local multicast | 329 AddMapping("ff32::2", "fe81::20"); // deprecated link-local multicast |
| 331 GetSourceInfo("fe81::20")->deprecated = true; | 330 GetSourceInfo("fe81::20")->deprecated = true; |
| 332 const char* const addresses[] = { "ff3e::1", "ff32::2", "4000::1", "ff32::1", | 331 const char* const addresses[] = { "ff3e::1", "ff32::2", "4000::1", "ff32::1", |
| 333 "::1", "8.0.0.1", NULL }; | 332 "::1", "8.0.0.1", NULL }; |
| 334 const int order[] = { 4, 3, 0, 2, 1, -1 }; | 333 const int order[] = { 4, 3, 0, 2, 1, -1 }; |
| 335 Verify(addresses, order); | 334 Verify(addresses, order); |
| 336 } | 335 } |
| 337 | 336 |
| 338 } // namespace net | 337 } // namespace net |
| OLD | NEW |