Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Do not use compatibility at function when libc has them
Baptiste Daroussin committed 11 years ago
commit 3999cdc5fb09c9e18c49ef1b2571d36b5953ff51
parent f436491a4dced5a6dab9f2e3d496f392292bd61a
2 files changed +10 -10
modified compat/bsd_compat.h
@@ -91,7 +91,7 @@ void closefrom(int lowfd);
#define	AT_SYMLINK_NOFOLLOW	0x200
#endif

-
#if !HAVE_FACCESSAT
+
#if !HAVE_DECL_FACCESSAT
int faccessat(int fd, const char *path, int mode, int flag);
#endif

@@ -99,15 +99,15 @@ int faccessat(int fd, const char *path, int mode, int flag);
int fstatat(int fd, const char *path, struct stat *buf, int flag);
#endif

-
#if !HAVE_OPENAT
+
#if !HAVE_DECL_OPENAT
int openat(int fd, const char *path, int flags, ...);
#endif

-
#if !HAVE_READLINKAT
+
#if !HAVE_DECL_READLINKAT
ssize_t readlinkat(int fd, const char *restrict path, char *restrict buf, size_t bufsize);
#endif

-
#if !HAVE_UNLINKAT
+
#if !HAVE_DECL_UNLINKAT
# ifndef AT_REMOVEDIR
#  define AT_REMOVEDIR	0x800
# endif
modified compat/file_at.c
@@ -33,7 +33,7 @@
#include <stdarg.h>
#include <unistd.h>

-
#if !HAVE_UNLINKAT || !HAVE_FSTATAT
+
#if !HAVE_DECL_UNLINKAT || !HAVE_DECL_FSTATAT

static pthread_mutex_t file_at_lock = PTHREAD_MUTEX_INITIALIZER;
static int file_at_dfd = -1;
@@ -92,7 +92,7 @@ file_chdir_unlock(int dfd)
}
#endif

-
#if !HAVE_FACCESSAT
+
#if !HAVE_DECL_FACCESSAT
int
faccessat(int fd, const char *path, int mode, int flag)
{
@@ -117,7 +117,7 @@ faccessat(int fd, const char *path, int mode, int flag)
}
#endif

-
#if !HAVE_READLINKAT
+
#if !HAVE_DECL_READLINKAT
ssize_t
readlinkat(int fd, const char *restrict path, char *restrict buf,
	   size_t bufsize)
@@ -134,7 +134,7 @@ readlinkat(int fd, const char *restrict path, char *restrict buf,
}
#endif

-
#if !HAVE_FSTATAT
+
#if !HAVE_DECL_FSTATAT
int
fstatat(int fd, const char *path, struct stat *buf, int flag)
{
@@ -154,7 +154,7 @@ fstatat(int fd, const char *path, struct stat *buf, int flag)
}
#endif

-
#if !HAVE_OPENAT
+
#if !HAVE_DECL_OPENAT
int
openat(int fd, const char *path, int flags, ...)
{
@@ -177,7 +177,7 @@ openat(int fd, const char *path, int flags, ...)
}
#endif

-
#if !HAVE_UNLINKAT
+
#if !HAVE_DECL_UNLINKAT
int
unlinkat(int fd, const char *path, int flag)
{