HomePhabricator

[sanitizer_common] Close superfluous file descriptors in spawned process

Description

[sanitizer_common] Close superfluous file descriptors in spawned process

Use attribute flag POSIX_SPAWN_CLOEXEC_DEFAULT in the call to
posix_spawn.

If this flag is set, then only file descriptors explicitly described by
the file_actions argument are available in the spawned process; all of
the other file descriptors are automatically closed in the spawned
process.

POSIX_SPAWN_CLOEXEC_DEFAULT is an Apple-specific extension.

Details

Committed
ylnAug 27 2019, 3:12 PM
Parents
rL370120: [dotest] Remove check for LLDB_TESTSUITE_FORCE_FINISH
Branches
Unknown
Tags
Unknown