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_config_service_posix.h" | 5 #include "net/dns/dns_config_service_posix.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 19 matching lines...) Expand all Loading... |
30 #if !defined(OS_ANDROID) | 30 #if !defined(OS_ANDROID) |
31 namespace internal { | 31 namespace internal { |
32 | 32 |
33 namespace { | 33 namespace { |
34 | 34 |
35 const base::FilePath::CharType* kFilePathHosts = | 35 const base::FilePath::CharType* kFilePathHosts = |
36 FILE_PATH_LITERAL("/etc/hosts"); | 36 FILE_PATH_LITERAL("/etc/hosts"); |
37 | 37 |
38 #if defined(OS_IOS) | 38 #if defined(OS_IOS) |
39 | 39 |
40 // There is no plublic API to watch the DNS configuration on iOS. | 40 // There is no public API to watch the DNS configuration on iOS. |
41 class DnsConfigWatcher { | 41 class DnsConfigWatcher { |
42 public: | 42 public: |
43 typedef base::Callback<void(bool succeeded)> CallbackType; | 43 typedef base::Callback<void(bool succeeded)> CallbackType; |
44 | 44 |
45 bool Watch(const CallbackType& callback) { | 45 bool Watch(const CallbackType& callback) { |
46 return false; | 46 return false; |
47 } | 47 } |
48 }; | 48 }; |
49 | 49 |
50 #elif !defined(OS_MACOSX) | 50 #elif !defined(OS_MACOSX) |
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
428 virtual void ReadNow() OVERRIDE {} | 428 virtual void ReadNow() OVERRIDE {} |
429 virtual bool StartWatching() OVERRIDE { return false; } | 429 virtual bool StartWatching() OVERRIDE { return false; } |
430 }; | 430 }; |
431 // static | 431 // static |
432 scoped_ptr<DnsConfigService> DnsConfigService::CreateSystemService() { | 432 scoped_ptr<DnsConfigService> DnsConfigService::CreateSystemService() { |
433 return scoped_ptr<DnsConfigService>(new StubDnsConfigService()); | 433 return scoped_ptr<DnsConfigService>(new StubDnsConfigService()); |
434 } | 434 } |
435 #endif | 435 #endif |
436 | 436 |
437 } // namespace net | 437 } // namespace net |
OLD | NEW |