From d3be139a93c578d1e055bfd5f6f79eda312091f9 Mon Sep 17 00:00:00 2001 From: dzwdz Date: Sun, 10 Jul 2022 23:17:27 +0200 Subject: syscalls: implement dup --- src/init/syscalls.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/init/syscalls.c') diff --git a/src/init/syscalls.c b/src/init/syscalls.c index 25fa134..7c2bb68 100644 --- a/src/init/syscalls.c +++ b/src/init/syscalls.c @@ -26,6 +26,10 @@ int _syscall_mount(handle_t h, const char __user *path, int len) { return _syscall(_SYSCALL_MOUNT, (int)h, (int)path, len, 0); } +handle_t _syscall_dup(handle_t from, handle_t to, int flags) { + return (handle_t)_syscall(_SYSCALL_DUP, (int)from, (int)to, flags, 0); +} + int _syscall_read(handle_t h, void __user *buf, size_t len, int offset) { return _syscall(_SYSCALL_READ, (int)h, (int)buf, (int)len, offset); } -- cgit v1.2.3