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

Issue 6674042: Make URLRequestHttpJob the only URLRequestJob concerned with FilterContext. (Closed)

Created:
9 years, 9 months ago by adamk
Modified:
5 years ago
CC:
chromium-reviews, cbentzel+watch_chromium.org, darin-cc_chromium.org, Paweł Hajdan Jr., eroman
Visibility:
Public.

Description

Make URLRequestHttpJob the only URLRequestJob concerned with FilterContext. In order to allow this, provide a new factory method in Filter to return a GZipFilter (used by URLRequestFileJob and URLRequestJobTrackerTest), and invert control so that URLRequestJobs are responsible for constructing filters. This is one step away from removing FilterContext as a base class of URLRequestJob, which will be tackled in a followup change. BUG=none TEST=net_unittests Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=78489

Patch Set 1 #

Total comments: 8

Patch Set 2 : Responded to comments from willchan #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+75 lines, -87 lines) Patch
M net/base/filter.h View 1 2 chunks +17 lines, -5 lines 0 comments Download
M net/base/filter.cc View 3 chunks +31 lines, -24 lines 1 comment Download
M net/url_request/url_request_file_job.h View 1 2 chunks +2 lines, -3 lines 0 comments Download
M net/url_request/url_request_file_job.cc View 1 2 chunks +4 lines, -9 lines 0 comments Download
M net/url_request/url_request_http_job.h View 1 1 chunk +1 line, -2 lines 0 comments Download
M net/url_request/url_request_http_job.cc View 1 2 chunks +8 lines, -8 lines 0 comments Download
M net/url_request/url_request_job.h View 1 1 chunk +6 lines, -15 lines 0 comments Download
M net/url_request/url_request_job.cc View 1 2 chunks +3 lines, -11 lines 0 comments Download
M net/url_request/url_request_job_tracker_unittest.cc View 1 1 chunk +3 lines, -10 lines 0 comments Download

Messages

Total messages: 7 (1 generated)
adamk
9 years, 9 months ago (2011-03-16 21:53:54 UTC) #1
willchan no longer on Chromium
http://codereview.chromium.org/6674042/diff/1/net/base/filter.h File net/base/filter.h (right): http://codereview.chromium.org/6674042/diff/1/net/base/filter.h#newcode146 net/base/filter.h:146: // types[1] = FILTER_TYPE_GZIP will cause data to first ...
9 years, 9 months ago (2011-03-16 23:13:16 UTC) #2
adamk
http://codereview.chromium.org/6674042/diff/1/net/base/filter.h File net/base/filter.h (right): http://codereview.chromium.org/6674042/diff/1/net/base/filter.h#newcode146 net/base/filter.h:146: // types[1] = FILTER_TYPE_GZIP will cause data to first ...
9 years, 9 months ago (2011-03-16 23:21:34 UTC) #3
willchan no longer on Chromium
LGTM
9 years, 9 months ago (2011-03-16 23:27:58 UTC) #4
eustas
https://codereview.chromium.org/6674042/diff/4001/net/base/filter.cc File net/base/filter.cc (left): https://codereview.chromium.org/6674042/diff/4001/net/base/filter.cc#oldcode377 net/base/filter.cc:377: delete filter_list; Won't this cause memleaks? Usage pattern is: ...
5 years ago (2015-12-01 12:57:23 UTC) #6
adamk
5 years ago (2015-12-01 18:29:47 UTC) #7
Message was sent while issue was closed.
On 2015/12/01 12:57:23, eustas wrote:
> https://codereview.chromium.org/6674042/diff/4001/net/base/filter.cc
> File net/base/filter.cc (left):
> 
>
https://codereview.chromium.org/6674042/diff/4001/net/base/filter.cc#oldcode377
> net/base/filter.cc:377: delete filter_list;
> Won't this cause memleaks?
> Usage pattern is:
> Filter* filter_list = NULL;
> ...
> filter_list = PrependNewFilter(..., filter_list);
> ...
> 
> filter_list is lost and there is no way to free the memory of already created
> filters.

I haven't worked on net stuff since...about the time of this patch, so I'm
afraid I can't meaningfully answer your question.

Powered by Google App Engine
This is Rietveld 408576698