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

Issue 323683002: net: FileStream cleanup (Closed)

Created:
6 years, 6 months ago by rvargas (doing something else)
Modified:
6 years, 6 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org
Visibility:
Public.

Description

net: FileStream cleanup Remove old "Async" prefix from a time when FileStream could perform sync operations, and use base::File methods instead of reimplement them. Remove a TODO from native_message_process_host given that we decided it is not worth moving that functionality to FileStream ATM. BUG=322664 TBR=sergeyu@chromium.org, kinuko@chromium.org R=hashimoto@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=278857

Patch Set 1 : #

Patch Set 2 : #

Total comments: 23

Patch Set 3 : Review feedback #

Total comments: 8

Patch Set 4 : More comments, fix init typo #

Total comments: 14

Patch Set 5 : Remove new methods #

Total comments: 4

Patch Set 6 : Add DCHECK, fix ASSERT message #

Total comments: 12
Unified diffs Side-by-side diffs Delta from patch set Stats (+176 lines, -233 lines) Patch
M base/files/file_posix.cc View 1 2 3 4 5 1 chunk +7 lines, -2 lines 2 comments Download
M base/files/file_unittest.cc View 1 2 1 chunk +17 lines, -0 lines 0 comments Download
M base/files/file_win.cc View 1 2 2 chunks +5 lines, -2 lines 0 comments Download
M chrome/browser/chromeos/drive/local_file_reader.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/extensions/api/messaging/native_message_process_host.h View 1 2 3 4 2 chunks +1 line, -2 lines 2 comments Download
M chrome/browser/extensions/api/messaging/native_message_process_host.cc View 1 2 3 4 2 chunks +1 line, -2 lines 2 comments Download
M net/base/file_stream.h View 1 2 3 4 2 chunks +1 line, -2 lines 0 comments Download
M net/base/file_stream.cc View 1 2 3 4 5 4 chunks +8 lines, -10 lines 0 comments Download
M net/base/file_stream_context.h View 1 2 3 4 5 chunks +24 lines, -44 lines 0 comments Download
M net/base/file_stream_context.cc View 3 4 7 chunks +21 lines, -11 lines 2 comments Download
M net/base/file_stream_context_posix.cc View 1 2 3 4 6 chunks +14 lines, -45 lines 2 comments Download
M net/base/file_stream_context_win.cc View 1 2 3 4 4 chunks +18 lines, -30 lines 2 comments Download
M net/base/file_stream_unittest.cc View 1 2 3 4 29 chunks +51 lines, -55 lines 0 comments Download
D net/base/file_stream_whence.h View 1 chunk +0 lines, -20 lines 0 comments Download
M net/base/mock_file_stream.h View 1 chunk +1 line, -1 line 0 comments Download
M net/base/mock_file_stream.cc View 1 chunk +1 line, -1 line 0 comments Download
M net/base/upload_file_element_reader.cc View 1 chunk +1 line, -1 line 0 comments Download
M net/net.gypi View 1 2 1 chunk +0 lines, -1 line 0 comments Download
M net/url_request/url_request_file_job.cc View 1 chunk +2 lines, -1 line 0 comments Download
M webkit/browser/blob/local_file_stream_reader.cc View 1 chunk +1 line, -1 line 0 comments Download
M webkit/browser/fileapi/local_file_stream_writer.cc View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 39 (0 generated)
rvargas (doing something else)
PTAL sergeyu -> extensions hashimoto -> everything
6 years, 6 months ago (2014-06-12 01:47:20 UTC) #1
Sergey Ulanov
https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h File net/base/file_stream.h (right): https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h#newcode99 net/base/file_stream.h:99: virtual int ReadNoBlocking(IOBuffer* buf, int buf_len, Do we really ...
6 years, 6 months ago (2014-06-12 08:10:21 UTC) #2
hashimoto
https://codereview.chromium.org/323683002/diff/220001/chrome/browser/extensions/api/messaging/native_message_process_host.h File chrome/browser/extensions/api/messaging/native_message_process_host.h (right): https://codereview.chromium.org/323683002/diff/220001/chrome/browser/extensions/api/messaging/native_message_process_host.h#newcode13 chrome/browser/extensions/api/messaging/native_message_process_host.h:13: #include "base/message_loop/message_loop.h" nit: No need to include this? https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream_context.h ...
6 years, 6 months ago (2014-06-12 13:03:37 UTC) #3
rvargas (doing something else)
Thanks https://codereview.chromium.org/323683002/diff/220001/chrome/browser/extensions/api/messaging/native_message_process_host.h File chrome/browser/extensions/api/messaging/native_message_process_host.h (right): https://codereview.chromium.org/323683002/diff/220001/chrome/browser/extensions/api/messaging/native_message_process_host.h#newcode13 chrome/browser/extensions/api/messaging/native_message_process_host.h:13: #include "base/message_loop/message_loop.h" On 2014/06/12 13:03:36, hashimoto wrote: > ...
6 years, 6 months ago (2014-06-13 02:49:11 UTC) #4
hashimoto
lgtm https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream_context_posix.cc File net/base/file_stream_context_posix.cc (right): https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream_context_posix.cc#newcode73 net/base/file_stream_context_posix.cc:73: base::MessageLoopForIO::WATCH_READ, &file_watcher_, this); On 2014/06/13 02:49:10, rvargas wrote: ...
6 years, 6 months ago (2014-06-13 06:10:42 UTC) #5
Sergey Ulanov
https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h File net/base/file_stream.h (right): https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h#newcode99 net/base/file_stream.h:99: virtual int ReadNoBlocking(IOBuffer* buf, int buf_len, On 2014/06/13 02:49:10, ...
6 years, 6 months ago (2014-06-13 19:31:50 UTC) #6
rvargas (doing something else)
Thanks! https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h File net/base/file_stream.h (right): https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h#newcode99 net/base/file_stream.h:99: virtual int ReadNoBlocking(IOBuffer* buf, int buf_len, On 2014/06/13 ...
6 years, 6 months ago (2014-06-13 19:58:24 UTC) #7
rvargas (doing something else)
+wtc to get another opinion about if it makes sense to add these methods to ...
6 years, 6 months ago (2014-06-13 21:12:57 UTC) #8
Sergey Ulanov
https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h File net/base/file_stream.h (right): https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h#newcode99 net/base/file_stream.h:99: virtual int ReadNoBlocking(IOBuffer* buf, int buf_len, On 2014/06/13 19:58:24, ...
6 years, 6 months ago (2014-06-14 00:58:22 UTC) #9
rvargas (doing something else)
https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h File net/base/file_stream.h (right): https://codereview.chromium.org/323683002/diff/220001/net/base/file_stream.h#newcode99 net/base/file_stream.h:99: virtual int ReadNoBlocking(IOBuffer* buf, int buf_len, On 2014/06/14 00:58:22, ...
6 years, 6 months ago (2014-06-14 01:42:55 UTC) #10
wtc
Review comments on patch set 4: Ricardo: if I only read the comments for ReadNonBlocking ...
6 years, 6 months ago (2014-06-16 23:01:44 UTC) #11
rvargas (doing something else)
Thanks Wan-Teh, I think the question that I'm pondering is, should we add the new ...
6 years, 6 months ago (2014-06-16 23:41:44 UTC) #12
wtc
On 2014/06/16 23:41:44, rvargas wrote: > > I think the question that I'm pondering is, ...
6 years, 6 months ago (2014-06-17 18:05:26 UTC) #13
rvargas (doing something else)
On 2014/06/17 18:05:26, wtc wrote: > On 2014/06/16 23:41:44, rvargas wrote: > > > > ...
6 years, 6 months ago (2014-06-17 19:16:12 UTC) #14
wtc
Ricardo: I agree with your assessment.
6 years, 6 months ago (2014-06-17 22:50:28 UTC) #15
rvargas (doing something else)
Thanks. I removed the new methods so this is now doing only the cleanup. https://codereview.chromium.org/323683002/diff/320001/base/files/file_posix.cc ...
6 years, 6 months ago (2014-06-18 01:36:38 UTC) #16
Sergey Ulanov
Native Messaging changes - LGTM
6 years, 6 months ago (2014-06-18 04:03:38 UTC) #17
rvargas (doing something else)
On 2014/06/18 04:03:38, Sergey Ulanov wrote: > Native Messaging changes - LGTM Thanks. hashimoto@, does ...
6 years, 6 months ago (2014-06-19 00:09:50 UTC) #18
hashimoto
slgtm https://codereview.chromium.org/323683002/diff/340001/base/files/file_posix.cc File base/files/file_posix.cc (right): https://codereview.chromium.org/323683002/diff/340001/base/files/file_posix.cc#newcode289 base/files/file_posix.cc:289: COMPILE_ASSERT(sizeof(int64) == sizeof(off_t), off_t_64_bit); nit: s/off_t_64_bit/off64_t_bit/? https://codereview.chromium.org/323683002/diff/340001/net/base/file_stream.cc File ...
6 years, 6 months ago (2014-06-19 01:51:56 UTC) #19
rvargas (doing something else)
Thanks! https://codereview.chromium.org/323683002/diff/340001/base/files/file_posix.cc File base/files/file_posix.cc (right): https://codereview.chromium.org/323683002/diff/340001/base/files/file_posix.cc#newcode289 base/files/file_posix.cc:289: COMPILE_ASSERT(sizeof(int64) == sizeof(off_t), off_t_64_bit); On 2014/06/19 01:51:56, hashimoto ...
6 years, 6 months ago (2014-06-19 17:11:43 UTC) #20
rvargas (doing something else)
The CQ bit was checked by rvargas@chromium.org
6 years, 6 months ago (2014-06-19 17:11:57 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rvargas@chromium.org/323683002/360001
6 years, 6 months ago (2014-06-19 17:13:46 UTC) #22
wtc
Patch set 6 LGTM. https://codereview.chromium.org/323683002/diff/360001/base/files/file_posix.cc File base/files/file_posix.cc (right): https://codereview.chromium.org/323683002/diff/360001/base/files/file_posix.cc#newcode286 base/files/file_posix.cc:286: return lseek64(file_.get(), static_cast<off64_t>(offset), The COMPILE_ASSERT ...
6 years, 6 months ago (2014-06-19 18:20:49 UTC) #23
rvargas (doing something else)
Thanks! https://codereview.chromium.org/323683002/diff/360001/base/files/file_posix.cc File base/files/file_posix.cc (right): https://codereview.chromium.org/323683002/diff/360001/base/files/file_posix.cc#newcode286 base/files/file_posix.cc:286: return lseek64(file_.get(), static_cast<off64_t>(offset), On 2014/06/19 18:20:49, wtc wrote: ...
6 years, 6 months ago (2014-06-19 18:46:43 UTC) #24
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-19 20:57:30 UTC) #25
commit-bot: I haz the power
Try jobs failed on following builders: android_aosp on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/android_aosp/builds/85527)
6 years, 6 months ago (2014-06-19 20:57:31 UTC) #26
rvargas (doing something else)
The CQ bit was checked by rvargas@chromium.org
6 years, 6 months ago (2014-06-20 00:28:19 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rvargas@chromium.org/323683002/360001
6 years, 6 months ago (2014-06-20 00:30:54 UTC) #28
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_aosp on tryserver.chromium ...
6 years, 6 months ago (2014-06-20 01:21:30 UTC) #29
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-20 01:30:53 UTC) #30
commit-bot: I haz the power
Try jobs failed on following builders: android_aosp on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/android_aosp/builds/85720)
6 years, 6 months ago (2014-06-20 01:30:54 UTC) #31
rvargas (doing something else)
The CQ bit was checked by rvargas@chromium.org
6 years, 6 months ago (2014-06-20 17:59:06 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rvargas@chromium.org/323683002/360001
6 years, 6 months ago (2014-06-20 18:01:14 UTC) #33
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_aosp on tryserver.chromium ...
6 years, 6 months ago (2014-06-20 18:19:33 UTC) #34
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-20 18:33:16 UTC) #35
commit-bot: I haz the power
Try jobs failed on following builders: android_aosp on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/android_aosp/builds/86092)
6 years, 6 months ago (2014-06-20 18:33:17 UTC) #36
rvargas (doing something else)
The CQ bit was checked by rvargas@chromium.org
6 years, 6 months ago (2014-06-20 22:12:20 UTC) #37
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rvargas@chromium.org/323683002/360001
6 years, 6 months ago (2014-06-20 22:14:26 UTC) #38
commit-bot: I haz the power
6 years, 6 months ago (2014-06-20 23:30:23 UTC) #39
Message was sent while issue was closed.
Change committed as 278857

Powered by Google App Engine
This is Rietveld 408576698