Commit 30761e83 by Serge E. Hallyn Committed by Daniel Lezcano

s390 sys_clone is backwards

Switch the flags and sp for sys_clone for s390. Without this, lxc-execute gets a segfault on clone (of course). With this, it succeeds. Signed-off-by: 's avatarSerge Hallyn <serue@us.ibm.com> Signed-off-by: 's avatarDaniel Lezcano <dlezcano@fr.ibm.com>
parent 47f38330
......@@ -60,8 +60,10 @@
# error "unsupported architecture"
# endif
#endif
#if __i386__ || __x86_64__ || __s390__ || __powerpc__
#if __i386__ || __x86_64__ || __powerpc__
# define fork_ns(flags) syscall(SYS_clone, flags|SIGCHLD, NULL)
#elif __s390__
# define fork_ns(flags) syscall(SYS_clone, NULL, flags|SIGCHLD)
#elif __ia64__
# define fork_ns(flags) syscall(SYS_clone2, flags|SIGCHLD, NULL)
#else
......
......@@ -60,8 +60,10 @@
# error "unsupported architecture"
# endif
#endif
#if __i386__ || __x86_64__ || __s390__ || __powerpc__
#if __i386__ || __x86_64__ || __powerpc__
# define fork_ns(flags) syscall(SYS_clone, flags|SIGCHLD, NULL);
#elif __s390__
# define fork_ns(flags) syscall(SYS_clone, NULL, flags|SIGCHLD)
#elif __ia64__
# define fork_ns(flags) syscall(SYS_clone2, flags|SIGCHLD, NULL);
#else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment