Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(581)

Side by Side Diff: net/url_request/url_request_context_builder.cc

Issue 379293002: Add AssertNoURLRequests() to URLRequestContext subclass destructors. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add to two omitted subclasses of subclasses of URLRequestContext. Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/url_request/url_request_context.h ('k') | net/url_request/url_request_test_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/url_request/url_request_context_builder.h" 5 #include "net/url_request/url_request_context_builder.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 } 158 }
159 return file_thread_.get(); 159 return file_thread_.get();
160 } 160 }
161 161
162 void set_transport_security_persister( 162 void set_transport_security_persister(
163 scoped_ptr<TransportSecurityPersister> transport_security_persister) { 163 scoped_ptr<TransportSecurityPersister> transport_security_persister) {
164 transport_security_persister = transport_security_persister.Pass(); 164 transport_security_persister = transport_security_persister.Pass();
165 } 165 }
166 166
167 protected: 167 protected:
168 virtual ~BasicURLRequestContext() {} 168 virtual ~BasicURLRequestContext() {
169 AssertNoURLRequests();
170 }
169 171
170 private: 172 private:
171 // Threads should be torn down last. 173 // Threads should be torn down last.
172 scoped_ptr<base::Thread> cache_thread_; 174 scoped_ptr<base::Thread> cache_thread_;
173 scoped_ptr<base::Thread> file_thread_; 175 scoped_ptr<base::Thread> file_thread_;
174 176
175 URLRequestContextStorage storage_; 177 URLRequestContextStorage storage_;
176 scoped_ptr<TransportSecurityPersister> transport_security_persister_; 178 scoped_ptr<TransportSecurityPersister> transport_security_persister_;
177 179
178 DISALLOW_COPY_AND_ASSIGN(BasicURLRequestContext); 180 DISALLOW_COPY_AND_ASSIGN(BasicURLRequestContext);
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 #endif // !defined(DISABLE_FTP_SUPPORT) 402 #endif // !defined(DISABLE_FTP_SUPPORT)
401 403
402 storage->set_job_factory(job_factory); 404 storage->set_job_factory(job_factory);
403 405
404 // TODO(willchan): Support sdch. 406 // TODO(willchan): Support sdch.
405 407
406 return context; 408 return context;
407 } 409 }
408 410
409 } // namespace net 411 } // namespace net
OLDNEW
« no previous file with comments | « net/url_request/url_request_context.h ('k') | net/url_request/url_request_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698