summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2017-08-10 19:46:23 +0200
committerMax Kellermann <max@musicpd.org>2017-08-10 19:46:23 +0200
commit0c1740982d4d1e2a7d945f0d59d0b207eda55485 (patch)
tree16b8cb03462d062ae12ff287e27ea9f7aafcc106 /src
parent3c7c0515d80900a2530805e5c5be620bb43f59a0 (diff)
system/fd_util: remove unused function open_cloexec()
Diffstat (limited to 'src')
-rw-r--r--src/system/fd_util.c20
-rw-r--r--src/system/fd_util.h7
2 files changed, 0 insertions, 27 deletions
diff --git a/src/system/fd_util.c b/src/system/fd_util.c
index d554ad796..72c1e830c 100644
--- a/src/system/fd_util.c
+++ b/src/system/fd_util.c
@@ -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
diff --git a/src/system/fd_util.h b/src/system/fd_util.h
index 1b0126f85..4442f32b4 100644
--- a/src/system/fd_util.h
+++ b/src/system/fd_util.h
@@ -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).
*