summaryrefslogtreecommitdiffstats
path: root/libc-top-half/musl/src/unistd/ftruncate.c
diff options
context:
space:
mode:
Diffstat (limited to 'libc-top-half/musl/src/unistd/ftruncate.c')
-rw-r--r--libc-top-half/musl/src/unistd/ftruncate.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/libc-top-half/musl/src/unistd/ftruncate.c b/libc-top-half/musl/src/unistd/ftruncate.c
new file mode 100644
index 0000000..b41be0f
--- /dev/null
+++ b/libc-top-half/musl/src/unistd/ftruncate.c
@@ -0,0 +1,9 @@
+#include <unistd.h>
+#include "syscall.h"
+
+int ftruncate(int fd, off_t length)
+{
+ return syscall(SYS_ftruncate, fd, __SYSCALL_LL_O(length));
+}
+
+weak_alias(ftruncate, ftruncate64);