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

Issue 2687713003: Stop base::OpenFile from leaking fds/handles into child procs. (Closed)

Created:
3 years, 10 months ago by grt (UTC plus 2)
Modified:
3 years, 10 months ago
Reviewers:
Mark Mentovai, gab
CC:
chromium-reviews, vmpstr+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Stop base::OpenFile from leaking fds/handles into child procs. BUG=688362 TEST=New FileUtilTest.OpenFileNoInheritance fails with previous impl, passes with new impl. Review-Url: https://codereview.chromium.org/2687713003 Cr-Commit-Position: refs/heads/master@{#449999} Committed: https://chromium.googlesource.com/chromium/src/+/d0bc44fa24fba9f483aaddae8e2c29df3524a5d6

Patch Set 1 #

Patch Set 2 : macOS fix #

Total comments: 26

Patch Set 3 : suppress glibc leak #

Total comments: 7

Patch Set 4 : addressed review comments #

Total comments: 6

Patch Set 5 : more review comments #

Total comments: 2

Patch Set 6 : gab comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+100 lines, -2 lines) Patch
M base/files/file_util.h View 1 chunk +3 lines, -1 line 0 comments Download
M base/files/file_util_posix.cc View 1 2 3 4 2 chunks +32 lines, -1 line 0 comments Download
M base/files/file_util_unittest.cc View 1 2 3 4 5 3 chunks +48 lines, -0 lines 0 comments Download
M base/files/file_util_win.cc View 1 2 3 4 5 2 chunks +14 lines, -0 lines 0 comments Download
M build/sanitizers/lsan_suppressions.cc View 1 2 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 46 (32 generated)
grt (UTC plus 2)
Hi Gab and Mark. This does more-or-less what was we were discussing. Any callers who ...
3 years, 10 months ago (2017-02-09 14:23:51 UTC) #14
Mark Mentovai
There is no magic character. Here’s the source for fopen() on Mac: https://opensource.apple.com/source/Libc/Libc-1158.30.7/stdio/FreeBSD/fopen.c.auto.html Flags are ...
3 years, 10 months ago (2017-02-09 15:15:16 UTC) #17
gab
Awesome, thanks! https://codereview.chromium.org/2687713003/diff/60001/base/files/file_util.h File base/files/file_util.h (right): https://codereview.chromium.org/2687713003/diff/60001/base/files/file_util.h#newcode312 base/files/file_util.h:312: // configured to not be propagated to ...
3 years, 10 months ago (2017-02-09 15:18:09 UTC) #18
grt (UTC plus 2)
On 2017/02/09 15:15:16, Mark Mentovai wrote: > There is no magic character. Here’s the source ...
3 years, 10 months ago (2017-02-09 15:56:21 UTC) #22
Mark Mentovai
grt (UTC plus 1) wrote: > On 2017/02/09 15:15:16, Mark Mentovai wrote: > > As ...
3 years, 10 months ago (2017-02-09 15:56:58 UTC) #23
grt (UTC plus 2)
Responses to some comments below. I will send up another patch set that addresses the ...
3 years, 10 months ago (2017-02-09 15:57:02 UTC) #24
gab
https://codereview.chromium.org/2687713003/diff/60001/base/files/file_util.h File base/files/file_util.h (right): https://codereview.chromium.org/2687713003/diff/60001/base/files/file_util.h#newcode312 base/files/file_util.h:312: // configured to not be propagated to child processes. ...
3 years, 10 months ago (2017-02-09 17:01:24 UTC) #26
grt (UTC plus 2)
Thanks. PTAL. https://codereview.chromium.org/2687713003/diff/60001/base/files/file_util_posix.cc File base/files/file_util_posix.cc (right): https://codereview.chromium.org/2687713003/diff/60001/base/files/file_util_posix.cc#newcode189 base/files/file_util_posix.cc:189: // non-Mac platforms (which do not support ...
3 years, 10 months ago (2017-02-10 09:37:21 UTC) #30
Mark Mentovai
LGTM https://codereview.chromium.org/2687713003/diff/120001/base/files/file_util_posix.cc File base/files/file_util_posix.cc (right): https://codereview.chromium.org/2687713003/diff/120001/base/files/file_util_posix.cc#newcode193 base/files/file_util_posix.cc:193: // Add |mode_char| immediately before the comma or ...
3 years, 10 months ago (2017-02-11 00:52:29 UTC) #33
grt (UTC plus 2)
Thanks. Any final comments from you, Gab? If no, please feel at liberty to check ...
3 years, 10 months ago (2017-02-13 07:53:28 UTC) #34
gab
lgtm % nit (sorry for delay was at offsite on Friday) https://codereview.chromium.org/2687713003/diff/140001/base/files/file_util_unittest.cc File base/files/file_util_unittest.cc (right): ...
3 years, 10 months ago (2017-02-13 15:10:01 UTC) #39
grt (UTC plus 2)
Thanks. https://codereview.chromium.org/2687713003/diff/140001/base/files/file_util_unittest.cc File base/files/file_util_unittest.cc (right): https://codereview.chromium.org/2687713003/diff/140001/base/files/file_util_unittest.cc#newcode273 base/files/file_util_unittest.cc:273: FAIL() << "Unimplemented"; On 2017/02/13 15:10:01, gab wrote: ...
3 years, 10 months ago (2017-02-13 16:16:40 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/2687713003/160001
3 years, 10 months ago (2017-02-13 16:17:14 UTC) #43
commit-bot: I haz the power
3 years, 10 months ago (2017-02-13 17:52:58 UTC) #46
Message was sent while issue was closed.
Committed patchset #6 (id:160001) as
https://chromium.googlesource.com/chromium/src/+/d0bc44fa24fba9f483aaddae8e2c...

Powered by Google App Engine
This is Rietveld 408576698