e194282943
Rtld did not set FD_CLOEXEC on its internal file descriptors; therefore, such a file descriptor may be passed to a process created by another thread running in parallel to dlopen() or fdlopen(). No other threads are expected to be running during parsing of the hints and libmap files but the file descriptors need not be passed to child processes so add O_CLOEXEC there as well. This change will break fdlopen() (as used by OpenPAM) on kernels without F_DUPFD_CLOEXEC (added in July). Note that running new userland on old kernels is not supported. Reviewed by: kib |
||
---|---|---|
.. | ||
amd64 | ||
arm | ||
i386 | ||
ia64 | ||
mips | ||
powerpc | ||
powerpc64 | ||
sparc64 | ||
debug.c | ||
debug.h | ||
libmap.c | ||
libmap.h | ||
Makefile | ||
malloc.c | ||
map_object.c | ||
rtld_lock.c | ||
rtld_lock.h | ||
rtld_printf.c | ||
rtld_printf.h | ||
rtld_tls.h | ||
rtld.1 | ||
rtld.c | ||
rtld.h | ||
Symbol.map | ||
xmalloc.c |