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

Issue 1178013004: Include-what-you-use cleanup for http_cache_transaction.* (Closed)

Created:
5 years, 6 months ago by Adam Rice
Modified:
5 years, 6 months ago
Reviewers:
gavinp
CC:
chromium-reviews, cbentzel+watch_chromium.org, gavinp+disk_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Include-what-you-use cleanup for http_cache_transaction.* Add missing includes to http_cache_transaction.h and http_cache_transaction.cc. Remove includes from http_cache_transaction.cc that duplicate those in http_cache_transaction.h. Remove includes from http_cache_transaction.cc that are no longer used. BUG=none TEST=net_unittests Committed: https://crrev.com/d4470367e93495c078f7443aecc20dab88d48165 Cr-Commit-Position: refs/heads/master@{#334998}

Patch Set 1 #

Total comments: 6

Patch Set 2 : Move io_buffer.h include to include file. #

Patch Set 3 : Rabse to fix merge error. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+19 lines, -17 lines) Patch
M net/http/http_cache_transaction.h View 1 1 chunk +11 lines, -0 lines 0 comments Download
M net/http/http_cache_transaction.cc View 1 2 2 chunks +8 lines, -17 lines 0 comments Download

Messages

Total messages: 9 (3 generated)
Adam Rice
5 years, 6 months ago (2015-06-17 10:13:05 UTC) #2
gavinp
lgtm, although I think you should pay attention to the IOBuffer thing. https://codereview.chromium.org/1178013004/diff/1/net/http/http_cache_transaction.cc File net/http/http_cache_transaction.cc ...
5 years, 6 months ago (2015-06-17 13:56:14 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1178013004/40001
5 years, 6 months ago (2015-06-18 03:57:40 UTC) #6
commit-bot: I haz the power
Committed patchset #3 (id:40001)
5 years, 6 months ago (2015-06-18 05:48:09 UTC) #7
commit-bot: I haz the power
Patchset 3 (id:??) landed as https://crrev.com/d4470367e93495c078f7443aecc20dab88d48165 Cr-Commit-Position: refs/heads/master@{#334998}
5 years, 6 months ago (2015-06-18 05:50:17 UTC) #8
Adam Rice
5 years, 6 months ago (2015-06-19 07:00:01 UTC) #9
Message was sent while issue was closed.
https://codereview.chromium.org/1178013004/diff/1/net/http/http_cache_transac...
File net/http/http_cache_transaction.cc (left):

https://codereview.chromium.org/1178013004/diff/1/net/http/http_cache_transac...
net/http/http_cache_transaction.cc:28: #include "base/rand_util.h"
On 2015/06/17 13:56:14, gavinp wrote:
> !!! Wow.

Yes.

https://codereview.chromium.org/1178013004/diff/1/net/http/http_cache_transac...
File net/http/http_cache_transaction.h (right):

https://codereview.chromium.org/1178013004/diff/1/net/http/http_cache_transac...
net/http/http_cache_transaction.h:10: 
On 2015/06/17 13:56:14, gavinp wrote:
> Should we also #include <stddef.h> for size_t?
> 
> (in an earlier comment on another review, I think I referred to <stdint.h> for
> this?)

Done.

This file still uses the deprecated integer types from basictypes.h. Changing
those would be more disruptive, so I left them alone.

https://codereview.chromium.org/1178013004/diff/1/net/http/http_cache_transac...
net/http/http_cache_transaction.h:34: class IOBuffer;
On 2015/06/17 13:56:14, gavinp wrote:
> We use a scoped_refptr of IOBuffer (read_buf_ on line 462). That makes using a
> forward declaration quite fragile; if any constructors or destructors are
> generated then we could blow up. Should we just add an include?
> 
> (I didn't know this even worked! I spent some time playing with it to convince
> myself that clang at least compiles scoped_refptr to a forward declared class,
> although it is pretty easy to generate a method that blows it up...)

No point in unnecessary excitement. I moved the io_buffer.h include to this
file.

Powered by Google App Engine
This is Rietveld 408576698