Signed-off-by: Derek Foreman <der...@osg.samsung.com> --- cursor/os-compatibility.c | 26 +------------------------- 1 file changed, 1 insertion(+), 25 deletions(-)
diff --git a/cursor/os-compatibility.c b/cursor/os-compatibility.c index 9791f97..6883a1d 100644 --- a/cursor/os-compatibility.c +++ b/cursor/os-compatibility.c @@ -35,30 +35,6 @@ #include "config.h" #include "os-compatibility.h" -#ifndef HAVE_MKOSTEMP -static int -set_cloexec_or_close(int fd) -{ - long flags; - - if (fd == -1) - return -1; - - flags = fcntl(fd, F_GETFD); - if (flags == -1) - goto err; - - if (fcntl(fd, F_SETFD, flags | FD_CLOEXEC) == -1) - goto err; - - return fd; - -err: - close(fd); - return -1; -} -#endif - static int create_tmpfile_cloexec(char *tmpname) { @@ -71,7 +47,7 @@ create_tmpfile_cloexec(char *tmpname) #else fd = mkstemp(tmpname); if (fd >= 0) { - fd = set_cloexec_or_close(fd); + fd = wl_os_set_cloexec_or_close(fd); unlink(tmpname); } #endif -- 2.7.0 _______________________________________________ wayland-devel mailing list wayland-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/wayland-devel