diff options
author | Peter S. Mazinger <ps.m@gmx.net> | 2005-12-08 20:07:39 +0000 |
---|---|---|
committer | Peter S. Mazinger <ps.m@gmx.net> | 2005-12-08 20:07:39 +0000 |
commit | 121d3f0fa26162682586580475aa96014fc47c53 (patch) | |
tree | 25afd97f645f3e4765fedc49ab30d213a6b8dc67 /libc | |
parent | 2449b843471c5af52f6a6333956caa1288f075c1 (diff) |
Try to mimic glibc sigaction, sjhill, could you please test w/ this version?
Diffstat (limited to 'libc')
-rw-r--r-- | libc/signal/sigaction.c | 13 | ||||
-rw-r--r-- | libc/signal/sigignore.c | 2 | ||||
-rw-r--r-- | libc/signal/sigintr.c | 2 | ||||
-rw-r--r-- | libc/signal/signal.c | 2 | ||||
-rw-r--r-- | libc/signal/sigset.c | 2 | ||||
-rw-r--r-- | libc/signal/sysv_signal.c | 2 | ||||
-rw-r--r-- | libc/sysdeps/linux/arm/sigaction.c | 8 | ||||
-rw-r--r-- | libc/sysdeps/linux/common/ssp.c | 2 | ||||
-rw-r--r-- | libc/sysdeps/linux/i386/sigaction.c | 8 | ||||
-rw-r--r-- | libc/sysdeps/linux/mips/sigaction.c | 8 | ||||
-rw-r--r-- | libc/sysdeps/linux/x86_64/sigaction.c | 12 |
11 files changed, 30 insertions, 31 deletions
diff --git a/libc/signal/sigaction.c b/libc/signal/sigaction.c index 0976e827c..c6fcddf80 100644 --- a/libc/signal/sigaction.c +++ b/libc/signal/sigaction.c @@ -32,8 +32,8 @@ /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden -__sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int +__libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct kernel_sigaction kact, koact; @@ -69,8 +69,8 @@ __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oa /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden -__sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int +__libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct old_kernel_sigaction kact, koact; @@ -102,6 +102,5 @@ __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oa #endif -strong_alias(__sigaction_internal,__libc_sigaction) -weak_alias(__sigaction_internal,__sigaction) -weak_alias(__sigaction_internal,sigaction) +hidden_weak_alias(__libc_sigaction,__sigaction) +weak_alias(__libc_sigaction,sigaction) diff --git a/libc/signal/sigignore.c b/libc/signal/sigignore.c index 490cc3814..3f8b8985f 100644 --- a/libc/signal/sigignore.c +++ b/libc/signal/sigignore.c @@ -18,7 +18,7 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define sigaction __sigaction_internal +#define sigaction __sigaction #define _GNU_SOURCE #include <errno.h> diff --git a/libc/signal/sigintr.c b/libc/signal/sigintr.c index c55d58618..797c52843 100644 --- a/libc/signal/sigintr.c +++ b/libc/signal/sigintr.c @@ -16,7 +16,7 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define sigaction __sigaction_internal +#define sigaction __sigaction #include <stddef.h> #include <signal.h> diff --git a/libc/signal/signal.c b/libc/signal/signal.c index f8355258a..9e489f637 100644 --- a/libc/signal/signal.c +++ b/libc/signal/signal.c @@ -18,7 +18,7 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define sigaction __sigaction_internal +#define sigaction __sigaction #include <errno.h> #include <signal.h> diff --git a/libc/signal/sigset.c b/libc/signal/sigset.c index 7860669b6..305cd96fb 100644 --- a/libc/signal/sigset.c +++ b/libc/signal/sigset.c @@ -16,7 +16,7 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define sigaction __sigaction_internal +#define sigaction __sigaction #include <errno.h> #define __need_NULL diff --git a/libc/signal/sysv_signal.c b/libc/signal/sysv_signal.c index 78c9696dd..608aef235 100644 --- a/libc/signal/sysv_signal.c +++ b/libc/signal/sysv_signal.c @@ -16,7 +16,7 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define sigaction __sigaction_internal +#define sigaction __sigaction #include <errno.h> #include <signal.h> diff --git a/libc/sysdeps/linux/arm/sigaction.c b/libc/sysdeps/linux/arm/sigaction.c index e2da4f87c..a2d27eb5a 100644 --- a/libc/sysdeps/linux/arm/sigaction.c +++ b/libc/sysdeps/linux/arm/sigaction.c @@ -46,7 +46,7 @@ extern void __default_rt_sa_restorer(void); /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct kernel_sigaction kact, koact; @@ -94,7 +94,7 @@ int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct old_kernel_sigaction kact, koact; @@ -127,6 +127,6 @@ int __sigaction_internal (int sig, const struct sigaction *act, struct sigaction } #endif -strong_alias(__sigaction_internal,__libc_sigaction) -weak_alias(__sigaction_internal, sigaction) +hidden_weak_alias(__libc_sigaction,__sigaction) +weak_alias(__libc_sigaction,sigaction) diff --git a/libc/sysdeps/linux/common/ssp.c b/libc/sysdeps/linux/common/ssp.c index 49d2cbf65..05e53c29d 100644 --- a/libc/sysdeps/linux/common/ssp.c +++ b/libc/sysdeps/linux/common/ssp.c @@ -31,7 +31,7 @@ #define closelog __closelog #define sigfillset __sigfillset_internal #define sigdelset __sigdelset_internal -#define sigaction __sigaction_internal +#define sigaction __sigaction #define kill __kill #include <string.h> diff --git a/libc/sysdeps/linux/i386/sigaction.c b/libc/sysdeps/linux/i386/sigaction.c index d7898c598..2e50284b2 100644 --- a/libc/sysdeps/linux/i386/sigaction.c +++ b/libc/sysdeps/linux/i386/sigaction.c @@ -34,7 +34,7 @@ extern void restore (void) asm ("__restore") attribute_hidden; /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct kernel_sigaction kact, koact; @@ -76,7 +76,7 @@ extern void restore (void) asm ("__restore") attribute_hidden; /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct old_kernel_sigaction kact, koact; @@ -119,8 +119,8 @@ int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, } #endif -strong_alias(__sigaction_internal,__libc_sigaction) -weak_alias(__sigaction_internal, sigaction) +hidden_weak_alias(__libc_sigaction,__sigaction) +weak_alias(__libc_sigaction,sigaction) diff --git a/libc/sysdeps/linux/mips/sigaction.c b/libc/sysdeps/linux/mips/sigaction.c index f703f33cd..dfc259801 100644 --- a/libc/sysdeps/linux/mips/sigaction.c +++ b/libc/sysdeps/linux/mips/sigaction.c @@ -32,7 +32,7 @@ /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct kernel_sigaction kact, koact; @@ -77,7 +77,7 @@ extern void restore (void) asm ("__restore") attribute_hidden; /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct old_kernel_sigaction kact, koact; @@ -118,5 +118,5 @@ int attribute_hidden __sigaction_internal (int sig, const struct sigaction *act, } #endif -strong_alias(__sigaction_internal,__libc_sigaction) -weak_alias(__sigaction_internal,sigaction) +hidden_weak_alias(__libc_sigaction,__sigaction) +weak_alias(__libc_sigaction,sigaction) diff --git a/libc/sysdeps/linux/x86_64/sigaction.c b/libc/sysdeps/linux/x86_64/sigaction.c index 32b13c064..41f9a8c8e 100644 --- a/libc/sysdeps/linux/x86_64/sigaction.c +++ b/libc/sysdeps/linux/x86_64/sigaction.c @@ -46,8 +46,8 @@ extern void restore (void) asm ("__restore") attribute_hidden; If OACT is not NULL, put the old action for SIG in *OACT. */ /* psm: couldn't use __sigaction, if building w/ disabled hidden, * it will conflict w/ the one in libpthread */ -int attribute_hidden -__sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int +__libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct kernel_sigaction kact, koact; @@ -79,8 +79,8 @@ extern void restore (void) asm ("__restore") attribute_hidden; /* If ACT is not NULL, change the action for SIG to *ACT. If OACT is not NULL, put the old action for SIG in *OACT. */ -int attribute_hidden -__sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oact) +int +__libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) { int result; struct old_kernel_sigaction kact, koact; @@ -119,8 +119,8 @@ __sigaction_internal (int sig, const struct sigaction *act, struct sigaction *oa return result; } #endif -strong_alias(__sigaction_internal,__libc_sigaction) -weak_alias(__sigaction_internal,sigaction) +hidden_weak_alias(__libc_sigaction,__sigaction) +weak_alias(__libc_sigaction,sigaction) /* NOTE: Please think twice before making any changes to the bits of code below. GDB needs some intimate knowledge about it to |