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

Issue 2404823002: Fix error handling in POSIX version of the base::File::GetLength. (Closed)

Created:
4 years, 2 months ago by Michael K. (Yandex Team)
Modified:
4 years ago
CC:
chromium-reviews
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix error handling in POSIX version of the base::File::GetLength. According to the base/files/file.h, the GetLength() method should return a negative number on failure. CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.win:win10_chromium_x64_rel_ng Committed: https://crrev.com/089ec1a2cbc7c118531871fece5ba2f1328e23ac Cr-Commit-Position: refs/heads/master@{#437512}

Patch Set 1 #

Patch Set 2 : Fix error handling in POSIX version of the base::File::GetLength. #

Total comments: 3

Patch Set 3 : Fix error handling in POSIX version of the base::File::GetLength. #

Patch Set 4 : Fix error handling in POSIX version of the base::File::GetLength. #

Patch Set 5 : Fix error handling in POSIX version of the base::File::GetLength. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+42 lines, -9 lines) Patch
M base/files/file_posix.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M base/files/memory_mapped_file_posix.cc View 1 2 chunks +7 lines, -2 lines 0 comments Download
M chrome/browser/media/webrtc/webrtc_browsertest_audio.cc View 1 1 chunk +15 lines, -2 lines 0 comments Download
M components/search_provider_logos/logo_cache_unittest.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M components/subresource_filter/core/browser/ruleset_service.cc View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M content/browser/renderer_host/media/audio_input_debug_writer_unittest.cc View 1 1 chunk +1 line, -0 lines 0 comments Download
M net/disk_cache/blockfile/file_ios.cc View 1 1 chunk +2 lines, -0 lines 0 comments Download
M net/disk_cache/blockfile/file_posix.cc View 1 1 chunk +2 lines, -0 lines 0 comments Download
M net/disk_cache/simple/simple_test_util.cc View 1 2 3 3 chunks +9 lines, -3 lines 0 comments Download
M sandbox/win/src/process_mitigations_test.cc View 1 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 61 (25 generated)
Michael K. (Yandex Team)
PTAL
4 years, 2 months ago (2016-10-10 10:45:08 UTC) #3
danakj
I wanted to look at callsites to make sure they're doing it right, but -1 ...
4 years, 2 months ago (2016-10-10 20:21:31 UTC) #4
Michael K. (Yandex Team)
Sorry for the delay. PTAL. On 2016/10/10 20:21:31, danakj wrote: > And here? > https://cs.chromium.org/chromium/src/components/nacl/renderer/plugin/pnacl_coordinator.cc?rcl=1476113755&l=179 ...
4 years ago (2016-11-23 06:49:25 UTC) #6
danakj
Thanks :) https://codereview.chromium.org/2404823002/diff/20001/net/disk_cache/blockfile/mapped_file.cc File net/disk_cache/blockfile/mapped_file.cc (right): https://codereview.chromium.org/2404823002/diff/20001/net/disk_cache/blockfile/mapped_file.cc#newcode26 net/disk_cache/blockfile/mapped_file.cc:26: if (!file_len) I don't think this is ...
4 years ago (2016-11-29 01:48:02 UTC) #7
Michael K. (Yandex Team)
Ok, I'll fix it. But just to be sure you've got it right: that GetLength() ...
4 years ago (2016-11-29 07:38:56 UTC) #8
danakj
On Mon, Nov 28, 2016 at 11:38 PM, <mkolom@yandex-team.ru> wrote: > Ok, I'll fix it. ...
4 years ago (2016-11-30 00:05:38 UTC) #9
Michael K. (Yandex Team)
On 2016/11/30 00:05:38, danakj wrote: > Do you agree what I'm asking will preserve the ...
4 years ago (2016-11-30 09:36:08 UTC) #10
danakj
There's no diff from patchset 2, looks like something went wrong with ur upload
4 years ago (2016-12-01 00:56:28 UTC) #11
Michael K. (Yandex Team)
On 2016/12/01 00:56:28, danakj wrote: > There's no diff from patchset 2, looks like something ...
4 years ago (2016-12-01 07:23:23 UTC) #12
danakj
Oh sorry, got it. LGTM
4 years ago (2016-12-02 00:15:39 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/40001
4 years ago (2016-12-02 07:59:41 UTC) #15
commit-bot: I haz the power
Try jobs failed on following builders: ios-device on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-device/builds/115898) ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, ...
4 years ago (2016-12-02 08:04:13 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/60001
4 years ago (2016-12-02 15:38:28 UTC) #20
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/317445)
4 years ago (2016-12-02 15:45:20 UTC) #22
Michael K. (Yandex Team)
I'm sorry: simple_test_util.cc was incompilable on non-MSVC :( PTAL.
4 years ago (2016-12-02 15:48:38 UTC) #23
danakj
LGTM. You'll need to grab owners for places outside of base/ though.
4 years ago (2016-12-02 23:56:13 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/60001
4 years ago (2016-12-03 16:04:56 UTC) #26
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/318086)
4 years ago (2016-12-03 16:09:12 UTC) #28
Michael K. (Yandex Team)
PTAL
4 years ago (2016-12-05 06:07:06 UTC) #31
engedy
LGTM on components/subresource_filter/.
4 years ago (2016-12-05 09:23:33 UTC) #32
justincohen
LGTM components/search_provider_logos/
4 years ago (2016-12-05 16:38:33 UTC) #33
agl
LGTM for net/
4 years ago (2016-12-05 16:42:40 UTC) #34
chcunningham
LGTM for renderer_host/media/audio_input_debug_writer_unittest.cc
4 years ago (2016-12-05 20:06:14 UTC) #35
phoglund_chromium
lgtm for webrtc code
4 years ago (2016-12-06 12:15:11 UTC) #36
Michael K. (Yandex Team)
jschuh, PTAL.
4 years ago (2016-12-08 09:52:13 UTC) #39
jschuh
On 2016/12/08 09:52:13, mkolom wrote: > jschuh, PTAL. sandbox lgtm
4 years ago (2016-12-08 13:38:31 UTC) #40
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/60001
4 years ago (2016-12-08 14:49:44 UTC) #42
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/82276)
4 years ago (2016-12-08 16:15:18 UTC) #44
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/60001
4 years ago (2016-12-08 16:49:53 UTC) #46
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/82442)
4 years ago (2016-12-08 18:19:47 UTC) #48
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/60001
4 years ago (2016-12-09 03:16:19 UTC) #50
commit-bot: I haz the power
Failed to apply patch for components/subresource_filter/core/browser/ruleset_service.cc: While running git apply --index -p1; error: patch failed: ...
4 years ago (2016-12-09 03:22:22 UTC) #52
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2404823002/80001
4 years ago (2016-12-09 09:18:20 UTC) #55
Michael K. (Yandex Team)
Rebased due to the conflict.
4 years ago (2016-12-09 09:18:33 UTC) #56
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years ago (2016-12-09 10:25:41 UTC) #59
commit-bot: I haz the power
4 years ago (2016-12-09 10:28:09 UTC) #61
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/089ec1a2cbc7c118531871fece5ba2f1328e23ac
Cr-Commit-Position: refs/heads/master@{#437512}

Powered by Google App Engine
This is Rietveld 408576698