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

Unified Diff: net/http/http_stream_factory_impl_job_controller.cc

Issue 2619583002: Clean up HttpStreamFactoryImpl::JobController when Impl::Jobs complete (Closed)
Patch Set: Created 3 years, 11 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: net/http/http_stream_factory_impl_job_controller.cc
diff --git a/net/http/http_stream_factory_impl_job_controller.cc b/net/http/http_stream_factory_impl_job_controller.cc
index 7e76ce5ce3436767ba5f47262d75ec4dbcaf16b8..686a68f7ca3ea9bc2cf406a80a915e95ce45262b 100644
--- a/net/http/http_stream_factory_impl_job_controller.cc
+++ b/net/http/http_stream_factory_impl_job_controller.cc
@@ -143,12 +143,10 @@ void HttpStreamFactoryImpl::JobController::OnRequestComplete() {
DCHECK(request_);
request_ = nullptr;
if (bound_job_) {
- if (bound_job_->job_type() == MAIN) {
- main_job_.reset();
- } else {
- DCHECK(bound_job_->job_type() == ALTERNATIVE);
- alternative_job_.reset();
- }
+ DCHECK(bound_job_->job_type() == MAIN ||
+ bound_job_->job_type() == ALTERNATIVE);
+ alternative_job_.reset();
+ main_job_.reset();
Wez 2017/01/06 18:21:44 So IIUC the issue was that MaybeNotifyFactoryOfCom
Ryan Sleevi 2017/01/06 20:24:13 A big +1 to that. A longer CL description that cov
bound_job_ = nullptr;
}
MaybeNotifyFactoryOfCompletion();

Powered by Google App Engine
This is Rietveld 408576698