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 // See header file for description of RendererDnsPrefetch class | 5 // See header file for description of RendererDnsPrefetch class |
6 | 6 |
7 #include "components/network_hints/renderer/renderer_dns_prefetch.h" | 7 #include "components/network_hints/renderer/renderer_dns_prefetch.h" |
8 | 8 |
9 #include <ctype.h> | 9 #include <ctype.h> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/location.h" | 12 #include "base/location.h" |
13 #include "base/logging.h" | 13 #include "base/logging.h" |
14 #include "base/message_loop/message_loop.h" | 14 #include "base/message_loop/message_loop.h" |
15 #include "base/thread_task_runner_handle.h" | |
16 #include "components/network_hints/common/network_hints_common.h" | 15 #include "components/network_hints/common/network_hints_common.h" |
17 #include "components/network_hints/common/network_hints_messages.h" | 16 #include "components/network_hints/common/network_hints_messages.h" |
18 #include "components/network_hints/renderer/dns_prefetch_queue.h" | 17 #include "components/network_hints/renderer/dns_prefetch_queue.h" |
19 #include "content/public/renderer/render_thread.h" | 18 #include "content/public/renderer/render_thread.h" |
20 | 19 |
21 using content::RenderThread; | 20 using content::RenderThread; |
22 | 21 |
23 namespace network_hints { | 22 namespace network_hints { |
24 | 23 |
25 RendererDnsPrefetch::RendererDnsPrefetch() | 24 RendererDnsPrefetch::RendererDnsPrefetch() |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 // Scan for a character outside our lookup list. | 162 // Scan for a character outside our lookup list. |
164 while (length-- > 0) { | 163 while (length-- > 0) { |
165 if (!isdigit(*name) && '.' != *name) | 164 if (!isdigit(*name) && '.' != *name) |
166 return false; | 165 return false; |
167 ++name; | 166 ++name; |
168 } | 167 } |
169 return true; | 168 return true; |
170 } | 169 } |
171 | 170 |
172 } // namespace predictor | 171 } // namespace predictor |
OLD | NEW |