Commit 0c174098 authored by Max Kellermann's avatar Max Kellermann

system/fd_util: remove unused function open_cloexec()

parent 3c7c0515
......@@ -102,26 +102,6 @@ fd_set_nonblock(int fd)
}
int
open_cloexec(const char *path_fs, int flags, int mode)
{
int fd;
#ifdef O_CLOEXEC
flags |= O_CLOEXEC;
#endif
#ifdef O_NOCTTY
flags |= O_NOCTTY;
#endif
fd = open(path_fs, flags, mode);
if (fd >= 0)
fd_set_cloexec(fd, true);
return fd;
}
int
pipe_cloexec_nonblock(int fd[2])
{
#ifdef WIN32
......
......@@ -55,13 +55,6 @@ int
fd_set_cloexec(int fd, bool enable);
/**
* Wrapper for open(), which sets the CLOEXEC flag (atomically if
* supported by the OS).
*/
int
open_cloexec(const char *path_fs, int flags, int mode);
/**
* Wrapper for pipe(), which sets the CLOEXEC flag (atomically if
* supported by the OS).
*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment