The sigsetmask() is deprecated in favor of sigprocmask().
Signed-off-by: Karel Zak <kzak@redhat.com>
}
if (errno == EWOULDBLOCK) {
int cpid, flags;
+ sigset_t sigmask;
if (forked) {
(void) close(fd);
/* 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));