diff options
author | Karel Zak | 2007-07-17 11:44:34 +0200 |
---|---|---|
committer | Karel Zak | 2007-07-17 11:44:34 +0200 |
commit | 1ed485b571c3a58560eca2701e502d737143c61c (patch) | |
tree | d709b99290269407d891c8d77478e5d6b30753c0 /login-utils/ttymsg.c | |
parent | fdisk: check returns in fdisk from partition changes (diff) | |
download | kernel-qcow2-util-linux-1ed485b571c3a58560eca2701e502d737143c61c.tar.gz kernel-qcow2-util-linux-1ed485b571c3a58560eca2701e502d737143c61c.tar.xz kernel-qcow2-util-linux-1ed485b571c3a58560eca2701e502d737143c61c.zip |
login-utils: remove deprecated sigsetmask() from wall
The sigsetmask() is deprecated in favor of sigprocmask().
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'login-utils/ttymsg.c')
-rw-r--r-- | login-utils/ttymsg.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/login-utils/ttymsg.c b/login-utils/ttymsg.c index 0dbe58113..24b74bcbc 100644 --- a/login-utils/ttymsg.c +++ b/login-utils/ttymsg.c @@ -128,6 +128,7 @@ ttymsg(struct iovec *iov, int iovcnt, char *line, int tmout) { } if (errno == EWOULDBLOCK) { int cpid, flags; + sigset_t sigmask; if (forked) { (void) close(fd); @@ -153,7 +154,8 @@ ttymsg(struct iovec *iov, int iovcnt, char *line, int tmout) { /* wait at most tmout seconds */ (void) signal(SIGALRM, SIG_DFL); (void) signal(SIGTERM, SIG_DFL); /* XXX */ - (void) sigsetmask(0); + sigemptyset(&sigmask); + sigprocmask (SIG_SETMASK, &sigmask, NULL); (void) alarm((u_int)tmout); flags = fcntl(fd, F_GETFL); fcntl(flags, F_SETFL, (long) (flags & ~O_NONBLOCK)); |