This is an archive of the discontinued LLVM Phabricator instance.

Avoid leaking log file descriptors into the inferior process.
ClosedPublic

Authored by labath on Feb 4 2015, 9:36 AM.

Details

Summary

This commit adds a new open flag File::eOpenOptionCloseOnExec (i.e., O_CLOEXEC), and adds it to
the list of flags when opening log files (#ifndef windows). A regression test is included.

Diff Detail

Repository
rL LLVM

Event Timeline

labath updated this revision to Diff 19322.Feb 4 2015, 9:36 AM
labath retitled this revision from to Avoid leaking log file descriptors into the inferior process..
labath updated this object.
labath edited the test plan for this revision. (Show Details)
labath added reviewers: vharron, clayborg.
labath added a subscriber: Unknown Object (MLST).
tberghammer added inline comments.
test/functionalities/avoids-fd-leak/TestFdLeak.py
19 ↗(On Diff #19322)

I think the test should be marked as skipped instead of expected failure because it is a problem in the test suit and not in lldb itself.

clayborg accepted this revision.Feb 4 2015, 11:00 AM
clayborg edited edge metadata.

lgtm

This revision is now accepted and ready to land.Feb 4 2015, 11:00 AM
This revision was automatically updated to reflect the committed changes.