diff options
author | Ulrich Drepper <drepper@redhat.com> | 2002-09-18 08:27:02 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2002-09-18 08:27:02 +0000 |
commit | ace55c73dd0c94e3cd77f53a046b6128a14a45e1 (patch) | |
tree | 910f71d06e0e63519bc4fa23593cc32a8bb350e5 | |
parent | b7cb624be9f0a59198e1a5f44cdee0a215440d27 (diff) | |
download | glibc-ace55c73dd0c94e3cd77f53a046b6128a14a45e1.zip glibc-ace55c73dd0c94e3cd77f53a046b6128a14a45e1.tar.gz glibc-ace55c73dd0c94e3cd77f53a046b6128a14a45e1.tar.bz2 |
Update.
* sysdeps/unix/sysv/linux/sigaction.c: If SIGCANCEL is defined
define sigaction and __sigaction as wrappers around
__libc_sigaction which rejects changing SIGCANCEL.
* sysdeps/unix/sysv/linux/i386/sigaction.c: Likewise.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/i386/sigaction.c | 19 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/sigaction.c | 19 |
3 files changed, 43 insertions, 0 deletions
@@ -1,5 +1,10 @@ 2002-09-18 Ulrich Drepper <drepper@redhat.com> + * sysdeps/unix/sysv/linux/sigaction.c: If SIGCANCEL is defined + define sigaction and __sigaction as wrappers around + __libc_sigaction which rejects changing SIGCANCEL. + * sysdeps/unix/sysv/linux/i386/sigaction.c: Likewise. + * sysdeps/unix/sysv/linux/i386/clone.S: Add support for SETTLS and SETTID/CLEARTID. diff --git a/sysdeps/unix/sysv/linux/i386/sigaction.c b/sysdeps/unix/sysv/linux/i386/sigaction.c index 57634c1..9474721 100644 --- a/sysdeps/unix/sysv/linux/i386/sigaction.c +++ b/sysdeps/unix/sysv/linux/i386/sigaction.c @@ -157,9 +157,28 @@ __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact) #endif } +#ifndef SIGCANCEL weak_alias (__libc_sigaction, __sigaction) libc_hidden_weak (__sigaction) weak_alias (__libc_sigaction, sigaction) +#else +int +__sigaction (sig, act, oact) + int sig; + const struct sigaction *act; + struct sigaction *oact; +{ + if (sig == SIGCANCEL) + { + __set_errno (EINVAL); + return -1; + } + + return __libc_sigaction (sig, act, oact); +} +libc_hidden_weak (__sigaction) +weak_alias (__sigaction, sigaction) +#endif /* NOTE: Please think twice before making any changes to the bits of code below. GDB needs some intimate knowledge about it to diff --git a/sysdeps/unix/sysv/linux/sigaction.c b/sysdeps/unix/sysv/linux/sigaction.c index c95e3d1..d8f1d26 100644 --- a/sysdeps/unix/sysv/linux/sigaction.c +++ b/sysdeps/unix/sysv/linux/sigaction.c @@ -133,6 +133,25 @@ __libc_sigaction (sig, act, oact) #endif } +#ifndef SIGCANCEL weak_alias (__libc_sigaction, __sigaction) libc_hidden_weak (__sigaction) weak_alias (__libc_sigaction, sigaction) +#else +int +__sigaction (sig, act, oact) + int sig; + const struct sigaction *act; + struct sigaction *oact; +{ + if (sig == SIGCANCEL) + { + __set_errno (EINVAL); + return -1; + } + + return __libc_sigaction (sig, act, oact); +} +libc_hidden_weak (__sigaction) +weak_alias (__sigaction, sigaction) +#endif |