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/proxy/dhcp_proxy_script_fetcher_win.h" | 5 #include "net/proxy/dhcp_proxy_script_fetcher_win.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
51 namespace net { | 51 namespace net { |
52 | 52 |
53 DhcpProxyScriptFetcherWin::DhcpProxyScriptFetcherWin( | 53 DhcpProxyScriptFetcherWin::DhcpProxyScriptFetcherWin( |
54 URLRequestContext* url_request_context) | 54 URLRequestContext* url_request_context) |
55 : state_(STATE_START), | 55 : state_(STATE_START), |
56 num_pending_fetchers_(0), | 56 num_pending_fetchers_(0), |
57 destination_string_(NULL), | 57 destination_string_(NULL), |
58 url_request_context_(url_request_context) { | 58 url_request_context_(url_request_context) { |
59 DCHECK(url_request_context_); | 59 DCHECK(url_request_context_); |
60 | 60 |
61 worker_pool_ = new base::SequencedWorkerPool(kMaxDhcpLookupThreads, | 61 worker_pool_ = |
62 "PacDhcpLookup"); | 62 new base::SequencedWorkerPool(kMaxDhcpLookupThreads, "PacDhcpLookup", |
eroman
2016/06/23 01:19:21
BTW I don't believe this actually has any ordering
gab
2016/06/27 21:29:32
Ack, will keep in mind for later, thanks!
| |
63 base::TaskPriority::USER_BLOCKING); | |
eroman
2016/06/23 01:19:21
USER_VISIBLE should be good enough for this.
As a
gab
2016/06/27 21:29:32
Done.
| |
63 } | 64 } |
64 | 65 |
65 DhcpProxyScriptFetcherWin::~DhcpProxyScriptFetcherWin() { | 66 DhcpProxyScriptFetcherWin::~DhcpProxyScriptFetcherWin() { |
66 // Count as user-initiated if we are not yet in STATE_DONE. | 67 // Count as user-initiated if we are not yet in STATE_DONE. |
67 Cancel(); | 68 Cancel(); |
68 | 69 |
69 worker_pool_->Shutdown(); | 70 worker_pool_->Shutdown(); |
70 } | 71 } |
71 | 72 |
72 int DhcpProxyScriptFetcherWin::Fetch(base::string16* utf16_text, | 73 int DhcpProxyScriptFetcherWin::Fetch(base::string16* utf16_text, |
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
374 | 375 |
375 bool DhcpProxyScriptFetcherWin::AdapterQuery::ImplGetCandidateAdapterNames( | 376 bool DhcpProxyScriptFetcherWin::AdapterQuery::ImplGetCandidateAdapterNames( |
376 std::set<std::string>* adapter_names) { | 377 std::set<std::string>* adapter_names) { |
377 return DhcpProxyScriptFetcherWin::GetCandidateAdapterNames(adapter_names); | 378 return DhcpProxyScriptFetcherWin::GetCandidateAdapterNames(adapter_names); |
378 } | 379 } |
379 | 380 |
380 DhcpProxyScriptFetcherWin::AdapterQuery::~AdapterQuery() { | 381 DhcpProxyScriptFetcherWin::AdapterQuery::~AdapterQuery() { |
381 } | 382 } |
382 | 383 |
383 } // namespace net | 384 } // namespace net |
OLD | NEW |