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

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

Issue 2910473005: Deprecate NonThreadSafe in net/ in favor of SequenceChecker/ThreadChecker. (Closed)
Patch Set: rebase on r476634 Created 3 years, 6 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
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.h" 5 #include "net/url_request/url_request_context.h"
6 6
7 #include <inttypes.h> 7 #include <inttypes.h>
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/debug/alias.h" 10 #include "base/debug/alias.h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 reporting_service_(nullptr), 51 reporting_service_(nullptr),
52 enable_brotli_(false), 52 enable_brotli_(false),
53 check_cleartext_permitted_(false), 53 check_cleartext_permitted_(false),
54 name_(nullptr), 54 name_(nullptr),
55 largest_outstanding_requests_count_seen_(0) { 55 largest_outstanding_requests_count_seen_(0) {
56 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider( 56 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider(
57 this, "URLRequestContext", base::ThreadTaskRunnerHandle::Get()); 57 this, "URLRequestContext", base::ThreadTaskRunnerHandle::Get());
58 } 58 }
59 59
60 URLRequestContext::~URLRequestContext() { 60 URLRequestContext::~URLRequestContext() {
61 DCHECK_CALLED_ON_VALID_THREAD(thread_checker_);
61 AssertNoURLRequests(); 62 AssertNoURLRequests();
62 base::trace_event::MemoryDumpManager::GetInstance()->UnregisterDumpProvider( 63 base::trace_event::MemoryDumpManager::GetInstance()->UnregisterDumpProvider(
63 this); 64 this);
64 } 65 }
65 66
66 void URLRequestContext::CopyFrom(const URLRequestContext* other) { 67 void URLRequestContext::CopyFrom(const URLRequestContext* other) {
67 // Copy URLRequestContext parameters. 68 // Copy URLRequestContext parameters.
68 set_net_log(other->net_log_); 69 set_net_log(other->net_log_);
69 set_host_resolver(other->host_resolver_); 70 set_host_resolver(other->host_resolver_);
70 set_cert_verifier(other->cert_verifier_); 71 set_cert_verifier(other->cert_verifier_);
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 HttpCache* http_cache = transaction_factory->GetCache(); 191 HttpCache* http_cache = transaction_factory->GetCache();
191 if (http_cache) 192 if (http_cache)
192 http_cache->DumpMemoryStats(pmd, dump->absolute_name()); 193 http_cache->DumpMemoryStats(pmd, dump->absolute_name());
193 } 194 }
194 if (sdch_manager_) 195 if (sdch_manager_)
195 sdch_manager_->DumpMemoryStats(pmd, dump_name); 196 sdch_manager_->DumpMemoryStats(pmd, dump_name);
196 return true; 197 return true;
197 } 198 }
198 199
199 } // namespace net 200 } // namespace net
OLDNEW
« no previous file with comments | « net/url_request/url_request_context.h ('k') | net/url_request/url_request_intercepting_job_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698