summaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv/linux/fallocate.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv/linux/fallocate.c')
-rw-r--r--sysdeps/unix/sysv/linux/fallocate.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/sysdeps/unix/sysv/linux/fallocate.c b/sysdeps/unix/sysv/linux/fallocate.c
index 6a58a5f50a..bc27ea7ab9 100644
--- a/sysdeps/unix/sysv/linux/fallocate.c
+++ b/sysdeps/unix/sysv/linux/fallocate.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2007-2016 Free Software Foundation, Inc.
+/* Copyright (C) 2007-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -19,17 +19,12 @@
#include <fcntl.h>
#include <sysdep-cancel.h>
-
+#ifndef __OFF_T_MATCHES_OFF64_T
/* Reserve storage for the data of the file associated with FD. */
int
fallocate (int fd, int mode, __off_t offset, __off_t len)
{
-#ifdef __NR_fallocate
return SYSCALL_CANCEL (fallocate, fd, mode,
- __LONG_LONG_PAIR (offset >> 31, offset),
- __LONG_LONG_PAIR (len >> 31, len));
-#else
- __set_errno (ENOSYS);
- return -1;
-#endif
+ SYSCALL_LL (offset), SYSCALL_LL (len));
}
+#endif