30 lines
701 B
Diff
30 lines
701 B
Diff
--- ./src/lib/syscall.c.orig 2021-12-03 18:08:08.498816181 +0100
|
|
+++ ./src/lib/syscall.c 2021-12-03 18:34:27.357373075 +0100
|
|
@@ -437,6 +437,26 @@
|
|
|
|
return tsocks_libc_syscall(TSOCKS_NR_MEMFD_CREATE, name, flags);
|
|
}
|
|
+
|
|
+
|
|
+/*
|
|
+ * * Handle clone(2) syscall.
|
|
+ * */
|
|
+static LIBC_SYSCALL_RET_TYPE handle_clone(va_list args)
|
|
+{
|
|
+ int (*fn)(void*);
|
|
+ void* child_stack;
|
|
+ int flags;
|
|
+ void* arg;
|
|
+
|
|
+ fn = va_arg(args, __typeof__(fn));
|
|
+ child_stack = va_arg(args, __typeof__(child_stack));
|
|
+ flags = va_arg(args, __typeof__(flags));
|
|
+ arg = va_arg(args, __typeof__(arg));
|
|
+
|
|
+ return tsocks_libc_syscall(TSOCKS_NR_CLONE, fn, child_stack, flags, arg);
|
|
+}
|
|
+
|
|
/*
|
|
* Handle getdents(2) syscall.
|
|
*/
|