diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2023-08-30 13:17:07 +0200 |
---|---|---|
committer | William Hubbs <w.d.hubbs@gmail.com> | 2023-09-12 22:53:12 -0500 |
commit | c199c5cf6e39d6e21b92bddba7beeebcc3afca79 (patch) | |
tree | 2c6f39ffe0f23aace0e70e8766fc731af3ba0f80 /src/shared/misc.h | |
parent | 5bfb592d75f2e2ccfc94cb510c5eca755767dfbb (diff) |
misc: add cloexec_fds_from() helper function
Move logic to set file descriptors to a cloexec_fds_from() function in
misc.c so it can be shared by both supervisor-daemon and
start-stop-daemon, and hide the details behind.
Diffstat (limited to 'src/shared/misc.h')
-rw-r--r-- | src/shared/misc.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/shared/misc.h b/src/shared/misc.h index f4ab25ad..b158a786 100644 --- a/src/shared/misc.h +++ b/src/shared/misc.h @@ -73,4 +73,6 @@ void from_time_t(char *time_string, time_t tv); time_t to_time_t(char *timestring); pid_t get_pid(const char *applet, const char *pidfile); +void cloexec_fds_from(int); + #endif |