1 diff -ruN tcp_wrappers_7.6.orig/rfc931.c tcp_wrappers_7.6/rfc931.c
2 --- tcp_wrappers_7.6.orig/rfc931.c 2004-08-29 18:40:08.000000000 +0200
3 +++ tcp_wrappers_7.6/rfc931.c 2004-08-29 18:40:02.000000000 +0200
6 char *result = unknown;
8 + unsigned saved_timeout;
9 + struct sigaction nact, oact;
12 /* address family must be the same */
16 if (setjmp(timebuf) == 0) {
17 - signal(SIGALRM, timeout);
18 + /* Save SIGALRM timer and handler. Sudheer Abdul-Salam, SUN. */
19 + saved_timeout = alarm(0);
20 + nact.sa_handler = timeout;
22 + (void) sigemptyset(&nact.sa_mask);
23 + (void) sigaction(SIGALRM, &nact, &oact);
24 alarm(rfc931_timeout);
31 + /* Restore SIGALRM timer and handler. Sudheer Abdul-Salam, SUN. */
32 + (void) sigaction(SIGALRM, &oact, NULL);
33 + if (saved_timeout > 0)
34 + alarm(saved_timeout);
37 STRN_CPY(dest, result, STRING_LENGTH);