OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/sync_host_resolver_bridge.h" | 5 #include "net/proxy/sync_host_resolver_bridge.h" |
6 | 6 |
7 #include "base/thread.h" | 7 #include "base/thread.h" |
8 #include "base/waitable_event.h" | 8 #include "base/waitable_event.h" |
9 #include "net/base/address_list.h" | 9 #include "net/base/address_list.h" |
10 #include "net/base/net_errors.h" | 10 #include "net/base/net_errors.h" |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 | 96 |
97 return rv; | 97 return rv; |
98 } | 98 } |
99 | 99 |
100 virtual void CancelRequest(RequestHandle request) { | 100 virtual void CancelRequest(RequestHandle request) { |
101 NOTREACHED(); | 101 NOTREACHED(); |
102 } | 102 } |
103 | 103 |
104 private: | 104 private: |
105 virtual int SetPacScript(const GURL& pac_url, | 105 virtual int SetPacScript(const GURL& pac_url, |
106 const std::string& bytes_utf8, | 106 const string16& pac_script, |
107 CompletionCallback* callback) { | 107 CompletionCallback* callback) { |
108 NOTREACHED(); | 108 NOTREACHED(); |
109 return OK; | 109 return OK; |
110 } | 110 } |
111 | 111 |
112 scoped_refptr<HostResolver> host_resolver_; | 112 scoped_refptr<HostResolver> host_resolver_; |
113 }; | 113 }; |
114 | 114 |
115 // This helper thread is used to create the circumstances for the deadlock. | 115 // This helper thread is used to create the circumstances for the deadlock. |
116 // It is analagous to the "IO thread" which would be main thread running the | 116 // It is analagous to the "IO thread" which would be main thread running the |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 // stop the IOThread, which will in turn delete the | 190 // stop the IOThread, which will in turn delete the |
191 // SingleThreadedProxyResolver, which in turn will stop its internal | 191 // SingleThreadedProxyResolver, which in turn will stop its internal |
192 // PAC thread (which is currently blocked waiting on the host resolve which | 192 // PAC thread (which is currently blocked waiting on the host resolve which |
193 // is running on IOThread). The IOThread::Cleanup() will verify that after | 193 // is running on IOThread). The IOThread::Cleanup() will verify that after |
194 // the PAC thread is stopped, it cancels the request on the HostResolver. | 194 // the PAC thread is stopped, it cancels the request on the HostResolver. |
195 } | 195 } |
196 | 196 |
197 } // namespace | 197 } // namespace |
198 | 198 |
199 } // namespace net | 199 } // namespace net |
OLD | NEW |