Mark every file descriptor equal to or greater than lowfd to be closed
at the next execve() or similar, as if via the FD_CLOEXEC flag.
Typically lowfd will be 3, to leave standard input, standard output
and standard error open after exec.
This is the same as Linux close_range (lowfd, ~0U, CLOSE_RANGE_CLOEXEC),
but portable to other OSs and to older versions of Linux.
This function is async-signal safe, making it safe to call from a
signal handler or a GLib.SpawnChildSetupFunc, as long as lowfd is
non-negative.
See signal(7) and
signal-safety(7) for more details.
Mark every file descriptor equal to or greater than
lowfdto be closed at the nextexecve()or similar, as if via theFD_CLOEXECflag.Typically
lowfdwill be 3, to leave standard input, standard output and standard error open after exec.This is the same as Linux
close_range (lowfd, ~0U, CLOSE_RANGE_CLOEXEC), but portable to other OSs and to older versions of Linux.This function is async-signal safe, making it safe to call from a signal handler or a GLib.SpawnChildSetupFunc, as long as
lowfdis non-negative. Seesignal(7)andsignal-safety(7)for more details.