summaryrefslogtreecommitdiff
path: root/src/unistd/ftruncate.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/unistd/ftruncate.c')
-rw-r--r--src/unistd/ftruncate.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/unistd/ftruncate.c b/src/unistd/ftruncate.c
new file mode 100644
index 0000000..54ff34b
--- /dev/null
+++ b/src/unistd/ftruncate.c
@@ -0,0 +1,7 @@
+#include <unistd.h>
+#include "syscall.h"
+
+int ftruncate(int fd, off_t length)
+{
+ return syscall(SYS_ftruncate, fd, __SYSCALL_LL_O(length));
+}