diff options
author | Peter S. Mazinger <ps.m@gmx.net> | 2011-05-08 00:57:57 +0200 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2012-06-15 14:00:44 +0200 |
commit | 5aa7aa7fa7ec2a0fe567ac0b2595b46add6f3594 (patch) | |
tree | 2d0d0277a1b517151dc4625983b23b851e129cb2 | |
parent | 52029220899bc6d566541de1e3da8cd21327e4a5 (diff) |
signal: remove sigblock, siggetmask and sigsetmask
rcmd.c uses sigblock and sigsetmask, make the function static and include them directly until
a rewrite is done.
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
-rw-r--r-- | include/signal.h | 14 | ||||
-rw-r--r-- | libc/inet/rpc/rcmd.c | 7 | ||||
-rw-r--r-- | libc/signal/Makefile.in | 4 | ||||
-rw-r--r-- | libc/signal/sigblock.c | 5 | ||||
-rw-r--r-- | libc/signal/sigsetmask.c | 5 |
5 files changed, 13 insertions, 22 deletions
diff --git a/include/signal.h b/include/signal.h index 41018565d..9763713d0 100644 --- a/include/signal.h +++ b/include/signal.h @@ -213,7 +213,7 @@ extern int sigpause(int __sig); #endif #endif /* __UCLIBC_SUSV4_LEGACY__ */ -#ifdef __USE_BSD +#if 0 /*def __USE_BSD*/ /* None of the following functions should be used anymore. They are here only for compatibility. A single word (`int') is not guaranteed to be enough to hold a complete signal mask and therefore these functions @@ -223,22 +223,10 @@ extern int sigpause(int __sig); # define sigmask(sig) __sigmask(sig) /* Block signals in MASK, returning the old mask. */ -# ifdef _LIBC -extern int sigblock (int __mask) __THROW; -/* collides with libc_hidden_proto: __attribute_deprecated__; */ -libc_hidden_proto(sigblock) -# else extern int sigblock (int __mask) __THROW __attribute_deprecated__; -# endif /* Set the mask of blocked signals to MASK, returning the old mask. */ -# ifdef _LIBC -extern int sigsetmask (int __mask) __THROW; -/* collides with libc_hidden_proto: __attribute_deprecated__; */ -libc_hidden_proto(sigsetmask) -# else extern int sigsetmask (int __mask) __THROW __attribute_deprecated__; -# endif /* Return currently selected signal mask. */ extern int siggetmask (void) __THROW __attribute_deprecated__; diff --git a/libc/inet/rpc/rcmd.c b/libc/inet/rpc/rcmd.c index ebeeb5b5a..fdfaa0908 100644 --- a/libc/inet/rpc/rcmd.c +++ b/libc/inet/rpc/rcmd.c @@ -86,6 +86,11 @@ static char sccsid[] = "@(#)rcmd.c 8.3 (Berkeley) 3/26/94"; #include <sys/uio.h> #include <bits/uClibc_alloc.h> +/* sigsetmask and sigblock are not provided anymore, until this file is corrected, + * include the sources */ +#include "../../signal/sigblock.c" +#include "../../signal/sigsetmask.c" + /* some forward declarations */ static int __ivaliduser2(FILE *hostf, u_int32_t raddr, @@ -145,7 +150,7 @@ int rcmd(char **ahost, u_short rport, const char *locuser, const char *remuser, pfd[1].events = POLLIN; *ahost = hp->h_name; - oldmask = sigblock(sigmask(SIGURG)); /* __sigblock */ + oldmask = sigblock(__sigmask(SIGURG)); /* sigblock */ for (timo = 1, lport = IPPORT_RESERVED - 1;;) { s = rresvport(&lport); if (s < 0) { diff --git a/libc/signal/Makefile.in b/libc/signal/Makefile.in index 1eaa9f07a..c9f74ee13 100644 --- a/libc/signal/Makefile.in +++ b/libc/signal/Makefile.in @@ -8,9 +8,9 @@ subdirs += libc/signal CSRC-y := allocrtsig.c killpg.c raise.c sigaction.c sigaddset.c sigandset.c \ - sigblock.c sigdelset.c sigempty.c sigfillset.c siggetmask.c \ + sigdelset.c sigempty.c sigfillset.c \ sigisempty.c sigismem.c sigjmp.c signal.c \ - sigorset.c sigsetmask.c sigsetops.c sigwait.c + sigorset.c sigsetops.c sigwait.c CSRC-$(UCLIBC_HAS_OBSOLETE_BSD_SIGNAL) += \ sighold.c sigignore.c sigrelse.c sigset.c CSRC-$(UCLIBC_HAS_OBSOLETE_SYSV_SIGNAL) += sysv_signal.c diff --git a/libc/signal/sigblock.c b/libc/signal/sigblock.c index c3ce36307..cb3b26519 100644 --- a/libc/signal/sigblock.c +++ b/libc/signal/sigblock.c @@ -16,13 +16,13 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define __UCLIBC_HIDE_DEPRECATED__ +/*#define __UCLIBC_HIDE_DEPRECATED__*/ #include <signal.h> #include "sigset-cvt-mask.h" /* Block signals in MASK, returning the old mask. */ -int sigblock (int mask) +static int sigblock (int mask) { sigset_t set, oset; @@ -30,4 +30,3 @@ int sigblock (int mask) sigprocmask (SIG_BLOCK, &set, &oset); /* can't fail */ return sigset_get_old_mask (&oset); } -libc_hidden_def(sigblock) diff --git a/libc/signal/sigsetmask.c b/libc/signal/sigsetmask.c index 0a731795d..df040a65d 100644 --- a/libc/signal/sigsetmask.c +++ b/libc/signal/sigsetmask.c @@ -16,13 +16,13 @@ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#define __UCLIBC_HIDE_DEPRECATED__ +/*#define __UCLIBC_HIDE_DEPRECATED__*/ #include <signal.h> #include "sigset-cvt-mask.h" /* Set the mask of blocked signals to MASK, returning the old mask. */ -int +static int sigsetmask (int mask) { sigset_t set, oset; @@ -31,4 +31,3 @@ sigsetmask (int mask) sigprocmask (SIG_SETMASK, &set, &oset); /* can't fail */ return sigset_get_old_mask (&oset); } -libc_hidden_def(sigsetmask) |