From a2dc2ddbb5a0b6a251783f1fe48f0169b2acc243 Mon Sep 17 00:00:00 2001 From: "Peter S. Mazinger" Date: Wed, 6 Apr 2011 12:37:52 +0200 Subject: splice,sync_file_range: mark them as GNU extensions They can't be compiled if LFS is disabled, they are using off64_t. Signed-off-by: Peter S. Mazinger Signed-off-by: Bernhard Reutner-Fischer --- libc/sysdeps/linux/common/sync_file_range.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'libc/sysdeps/linux/common/sync_file_range.c') diff --git a/libc/sysdeps/linux/common/sync_file_range.c b/libc/sysdeps/linux/common/sync_file_range.c index d24403e1b..b07f8e501 100644 --- a/libc/sysdeps/linux/common/sync_file_range.c +++ b/libc/sysdeps/linux/common/sync_file_range.c @@ -8,14 +8,15 @@ */ #include -#if defined __USE_GNU -#include -#if defined __NR_sync_file_range && defined __UCLIBC_HAS_LFS__ -#define __NR___syscall_sync_file_range __NR_sync_file_range +#if defined __NR_sync_file_range && defined __UCLIBC_HAS_LFS__ && defined __USE_GNU +# include + +# define __NR___syscall_sync_file_range __NR_sync_file_range static __inline__ _syscall6(int, __syscall_sync_file_range, int, fd, - off_t, offset_hi, off_t, offset_lo, - off_t, nbytes_hi, off_t, nbytes_lo, unsigned int, flags) + off_t, offset_hi, off_t, offset_lo, + off_t, nbytes_hi, off_t, nbytes_lo, unsigned int, flags) + int sync_file_range(int fd, off64_t offset, off64_t nbytes, unsigned int flags) { return __syscall_sync_file_range(fd, @@ -24,4 +25,3 @@ int sync_file_range(int fd, off64_t offset, off64_t nbytes, unsigned int flags) flags); } #endif -#endif -- cgit v1.2.3