[RFC PATCH 26/38] getdents: fall back to getdents64
Jonas Bonn
jonas at southpole.se
Tue Sep 6 08:30:50 UTC 2011
Signed-off-by: Jonas Bonn <jonas at southpole.se>
---
libc/sysdeps/linux/common/getdents.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/libc/sysdeps/linux/common/getdents.c b/libc/sysdeps/linux/common/getdents.c
index 46f7b8e..e886d64 100644
--- a/libc/sysdeps/linux/common/getdents.c
+++ b/libc/sysdeps/linux/common/getdents.c
@@ -44,10 +44,12 @@ struct kernel_dirent
ssize_t __getdents (int fd, char *buf, size_t nbytes) attribute_hidden;
+#ifdef __NR_getdents
#define __NR___syscall_getdents __NR_getdents
static __always_inline _syscall3(int, __syscall_getdents, int, fd, unsigned char *, kdirp, size_t, count)
+#endif
-#if defined __ASSUME_GETDENTS32_D_TYPE
+#if defined __ASSUME_GETDENTS32_D_TYPE && defined __NR_getdents
ssize_t __getdents (int fd, char *buf, size_t nbytes)
{
--
1.7.5.4
More information about the uClibc
mailing list