From 8a7e183ed3cf372563dc263066035870c3ea6995 Mon Sep 17 00:00:00 2001 From: Paper Date: Mon, 29 Jan 2024 10:49:07 -0500 Subject: add posix_fallocate64() wrapper Signed-off-by: Paper --- Makefile | 1 + libgcompat/fcntl.c | 10 ++++++++++ 2 files changed, 11 insertions(+) create mode 100644 libgcompat/fcntl.c diff --git a/Makefile b/Makefile index cbb7634..c84b6f9 100644 --- a/Makefile +++ b/Makefile @@ -10,6 +10,7 @@ LIBGCOMPAT_SRC = \ libgcompat/gnulib.c \ libgcompat/grp.c \ libgcompat/internal.c \ + libgcompat/fcntl.c \ libgcompat/locale.c \ libgcompat/malloc.c \ libgcompat/math.c \ diff --git a/libgcompat/fcntl.c b/libgcompat/fcntl.c new file mode 100644 index 0000000..95de206 --- /dev/null +++ b/libgcompat/fcntl.c @@ -0,0 +1,10 @@ +#include /* posix_fallocate */ + +typedef long long off64_t; + +/* + * posix_fallocate64: gnu-ified 64-bit posix_fallocate +*/ +int posix_fallocate64(int fd, off64_t offset, off64_t len) { + return posix_fallocate(fd, offset, len); +} -- cgit v1.2.3-70-g09d2