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

Unified Diff: components/update_client/url_request_post_interceptor.cc

Issue 2889683003: Rename TaskRunner::RunsTasksOnCurrentThread() in //components (Closed)
Patch Set: Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: components/update_client/url_request_post_interceptor.cc
diff --git a/components/update_client/url_request_post_interceptor.cc b/components/update_client/url_request_post_interceptor.cc
index 9753cb9fa99905baa4555614abfd0aac3ff1e95b..152747da794460136b4b9ee48420880ca9ae2a1b 100644
--- a/components/update_client/url_request_post_interceptor.cc
+++ b/components/update_client/url_request_post_interceptor.cc
@@ -67,7 +67,7 @@ URLRequestPostInterceptor::URLRequestPostInterceptor(
}
URLRequestPostInterceptor::~URLRequestPostInterceptor() {
- DCHECK(io_task_runner_->RunsTasksOnCurrentThread());
+ DCHECK(io_task_runner_->RunsTasksInCurrentSequence());
ClearExpectations();
}
@@ -154,13 +154,13 @@ class URLRequestPostInterceptor::Delegate : public net::URLRequestInterceptor {
: scheme_(scheme), hostname_(hostname), io_task_runner_(io_task_runner) {}
void Register() {
- DCHECK(io_task_runner_->RunsTasksOnCurrentThread());
+ DCHECK(io_task_runner_->RunsTasksInCurrentSequence());
net::URLRequestFilter::GetInstance()->AddHostnameInterceptor(
scheme_, hostname_, std::unique_ptr<net::URLRequestInterceptor>(this));
}
void Unregister() {
- DCHECK(io_task_runner_->RunsTasksOnCurrentThread());
+ DCHECK(io_task_runner_->RunsTasksInCurrentSequence());
for (InterceptorMap::iterator it = interceptors_.begin();
it != interceptors_.end(); ++it)
delete (*it).second;
@@ -169,7 +169,7 @@ class URLRequestPostInterceptor::Delegate : public net::URLRequestInterceptor {
}
void OnCreateInterceptor(URLRequestPostInterceptor* interceptor) {
- DCHECK(io_task_runner_->RunsTasksOnCurrentThread());
+ DCHECK(io_task_runner_->RunsTasksInCurrentSequence());
DCHECK(interceptors_.find(interceptor->GetUrl()) == interceptors_.end());
interceptors_.insert(std::make_pair(interceptor->GetUrl(), interceptor));
@@ -181,7 +181,7 @@ class URLRequestPostInterceptor::Delegate : public net::URLRequestInterceptor {
net::URLRequestJob* MaybeInterceptRequest(
net::URLRequest* request,
net::NetworkDelegate* network_delegate) const override {
- DCHECK(io_task_runner_->RunsTasksOnCurrentThread());
+ DCHECK(io_task_runner_->RunsTasksInCurrentSequence());
// Only intercepts POST.
if (!request->has_upload())

Powered by Google App Engine
This is Rietveld 408576698