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_hosts.h" | 5 #include "net/dns/dns_hosts.h" |
6 | 6 |
7 #include "base/file_util.h" | 7 #include "base/files/file_util.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
11 | 11 |
12 using base::StringPiece; | 12 using base::StringPiece; |
13 | 13 |
14 namespace net { | 14 namespace net { |
15 | 15 |
16 namespace { | 16 namespace { |
17 | 17 |
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
205 std::string contents; | 205 std::string contents; |
206 if (!base::ReadFileToString(path, &contents)) | 206 if (!base::ReadFileToString(path, &contents)) |
207 return false; | 207 return false; |
208 | 208 |
209 ParseHosts(contents, dns_hosts); | 209 ParseHosts(contents, dns_hosts); |
210 return true; | 210 return true; |
211 } | 211 } |
212 | 212 |
213 } // namespace net | 213 } // namespace net |
214 | 214 |
OLD | NEW |