summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2006-01-24 17:18:19 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2006-01-24 17:18:19 +0000
commit48143d8a8f92fd69d95564516fd1b7cf122511b1 (patch)
tree60b6a07f9836b7885e6ee2cc2bfead197b554e2b /libc/sysdeps/linux/common
parentc3f6501060987d967a28495b009cd0da9da25252 (diff)
fork/vfork weak in libc, strong in libpthread
Diffstat (limited to 'libc/sysdeps/linux/common')
-rw-r--r--libc/sysdeps/linux/common/fork.c2
-rw-r--r--libc/sysdeps/linux/common/vfork.c13
2 files changed, 9 insertions, 6 deletions
diff --git a/libc/sysdeps/linux/common/fork.c b/libc/sysdeps/linux/common/fork.c
index 13c57237c..eb4001f7e 100644
--- a/libc/sysdeps/linux/common/fork.c
+++ b/libc/sysdeps/linux/common/fork.c
@@ -15,7 +15,7 @@
#define __NR___libc_fork __NR_fork
_syscall0(pid_t, __libc_fork);
libc_hidden_proto(fork)
-strong_alias(__libc_fork,fork)
+weak_alias(__libc_fork,fork)
libc_hidden_def(fork)
#endif
#endif
diff --git a/libc/sysdeps/linux/common/vfork.c b/libc/sysdeps/linux/common/vfork.c
index b3543a616..f668a020f 100644
--- a/libc/sysdeps/linux/common/vfork.c
+++ b/libc/sysdeps/linux/common/vfork.c
@@ -1,18 +1,21 @@
+/*
+ * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
/* Trivial implementation for arches that lack vfork */
#include <unistd.h>
#include <sys/types.h>
#include <sys/syscall.h>
#ifdef __NR_fork
-
-libc_hidden_proto(vfork)
-
libc_hidden_proto(fork)
-pid_t vfork(void)
+pid_t attribute_hidden __vfork(void)
{
return fork();
}
+libc_hidden_proto(vfork)
+weak_alias(__vfork,vfork)
libc_hidden_def(vfork)
-
#endif