Displaying 1 result from an estimated 1 matches for "f_noninheritable".
2017 Jan 17
3
O_CLOEXEC-like functionality for llvm::raw_fd_ostream
...LLVM streams more extensively in LLDB (which
currently rolls it's own stream classes). One of the things that's
missing for me to be able to do that is the ability to open a file
with the O_CLOEXEC flag (to prevent us leaking file descriptors into
the debugged process).
So I tried adding a F_NonInheritable flag to the raw_fd_ostream
constructor, which would map to O_CLOEXEC on unix, and non-inheritable
handles on windows. However, I encountered a discrepancy in the
current behavior there.
The current behavior on unix is to make the file descriptors
inheritable (as that is the platform default). On w...