Use sys_clone in Eclone.
authorDaniel Hokka Zakrisson <daniel@hozac.com>
Tue, 15 Jul 2008 22:14:13 +0000 (22:14 +0000)
committerDaniel Hokka Zakrisson <daniel@hozac.com>
Tue, 15 Jul 2008 22:14:13 +0000 (22:14 +0000)
git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2747 94cd875c-1c1d-0410-91d2-eb244daf1a30

ensc_wrappers/wrappers-clone.hc

index 943514f..eb36fc3 100644 (file)
 #  error wrappers_handler.hc can not be used in this way
 #endif
 
+#include <lib_internal/sys_clone.h>
+
 inline static WRAPPER_DECL pid_t
-Eclone(int (*fn)(void *), void *child_stack, int flags, void *arg)
+Eclone(uint64_t flags, void *child_stack)
 {
   pid_t                res;
-#ifndef __dietlibc__
-  res = clone(fn, child_stack, flags, arg);
-#else
-  res = clone((void*(*)(void*))(fn), child_stack, flags, arg);
-#endif
+  res = sys_clone(flags, child_stack);
   FatalErrnoError(res==-1, "clone()");
   return res;
 }