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

Issue 229893002: Add unit test to check for broker FD leak (Closed)

Created:
6 years, 8 months ago by mdempsky
Modified:
6 years, 8 months ago
CC:
chromium-reviews, agl, jln+watch_chromium.org
Visibility:
Public.

Description

Add unit test to check for broker FD leak BUG=360274 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=263147

Patch Set 1 #

Total comments: 1

Patch Set 2 : Be more explicit about allowing noisy tests #

Total comments: 6

Patch Set 3 : Make unit test fd handling more robust #

Total comments: 1

Patch Set 4 : Add BrokerProcessTestHelper to avoid hard-coding macro-generated identifiers #

Total comments: 8

Patch Set 5 : Ensure available_fds[0] is closed too #

Unified diffs Side-by-side diffs Delta from patch set Stats (+90 lines, -0 lines) Patch
M sandbox/linux/services/broker_process.h View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M sandbox/linux/services/broker_process_unittest.cc View 1 2 3 4 3 chunks +59 lines, -0 lines 0 comments Download
M sandbox/linux/tests/unit_tests.h View 1 3 chunks +13 lines, -0 lines 0 comments Download
M sandbox/linux/tests/unit_tests.cc View 1 1 chunk +11 lines, -0 lines 0 comments Download
M sandbox/linux/tests/unit_tests_unittest.cc View 1 2 chunks +5 lines, -0 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
mdempsky
6 years, 8 months ago (2014-04-09 00:43:49 UTC) #1
mdempsky
Reworked the test to use a new SANDBOX_TEST_ALLOW_NOISE() macro and documented why we need that ...
6 years, 8 months ago (2014-04-09 01:13:42 UTC) #2
jln (very slow on Chromium)
I'm sorry if this seems nit-picky, but I've been too burned by flaky tests in ...
6 years, 8 months ago (2014-04-09 02:25:47 UTC) #3
jln (very slow on Chromium)
https://codereview.chromium.org/229893002/diff/20001/sandbox/linux/services/broker_process_unittest.cc File sandbox/linux/services/broker_process_unittest.cc (right): https://codereview.chromium.org/229893002/diff/20001/sandbox/linux/services/broker_process_unittest.cc#newcode442 sandbox/linux/services/broker_process_unittest.cc:442: const int min_fd = dup(STDIN_FILENO); > You could also ...
6 years, 8 months ago (2014-04-09 02:32:09 UTC) #4
mdempsky
I reworked it a bit, and I think it should be way more robust. It's ...
6 years, 8 months ago (2014-04-09 23:29:40 UTC) #5
jln (very slow on Chromium)
https://chromiumcodereview.appspot.com/229893002/diff/60001/sandbox/linux/services/broker_process_unittest.cc File sandbox/linux/services/broker_process_unittest.cc (right): https://chromiumcodereview.appspot.com/229893002/diff/60001/sandbox/linux/services/broker_process_unittest.cc#newcode449 sandbox/linux/services/broker_process_unittest.cc:449: // Find the four lowest available file descriptors. Replace ...
6 years, 8 months ago (2014-04-10 20:21:15 UTC) #6
mdempsky
https://codereview.chromium.org/229893002/diff/60001/sandbox/linux/services/broker_process_unittest.cc File sandbox/linux/services/broker_process_unittest.cc (right): https://codereview.chromium.org/229893002/diff/60001/sandbox/linux/services/broker_process_unittest.cc#newcode449 sandbox/linux/services/broker_process_unittest.cc:449: // Find the four lowest available file descriptors. On ...
6 years, 8 months ago (2014-04-10 20:35:50 UTC) #7
jln (very slow on Chromium)
lgtm, thanks Matthew!
6 years, 8 months ago (2014-04-10 20:44:46 UTC) #8
mdempsky
The CQ bit was checked by mdempsky@chromium.org
6 years, 8 months ago (2014-04-10 20:47:27 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/mdempsky@chromium.org/229893002/80001
6 years, 8 months ago (2014-04-10 20:47:37 UTC) #10
commit-bot: I haz the power
6 years, 8 months ago (2014-04-11 00:44:21 UTC) #11
Message was sent while issue was closed.
Change committed as 263147

Powered by Google App Engine
This is Rietveld 408576698