From: Stelian Pop Date: Sat, 19 Aug 2000 22:06:03 +0000 (+0000) Subject: Fixed the signal handling in dump. X-Git-Tag: release_0_4b19~10 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=f1d86882fdf588f2678386b3824a5d20eebc4099;p=dump.git Fixed the signal handling in dump. --- diff --git a/CHANGES b/CHANGES index f5126aa..5d717ad 100644 --- a/CHANGES +++ b/CHANGES @@ -1,4 +1,11 @@ -$Id: CHANGES,v 1.68 2000/06/30 09:12:14 stelian Exp $ +$Id: CHANGES,v 1.69 2000/08/19 22:06:03 stelian Exp $ + +Changes between versions 0.4b17 and 0.4b19 (released ?????????????) +=================================================================== + +1. Fixed the signal handling in dump (which I broke in 0.4b17) + which was causing several strange dump failures (dump + hanged or segmentation faults etc). Changes between versions 0.4b17 and 0.4b18 (released June 30, 2000) =================================================================== diff --git a/dump/tape.c b/dump/tape.c index c104667..851a5cd 100644 --- a/dump/tape.c +++ b/dump/tape.c @@ -40,7 +40,7 @@ #ifndef lint static const char rcsid[] = - "$Id: tape.c,v 1.20 2000/06/01 18:30:08 stelian Exp $"; + "$Id: tape.c,v 1.21 2000/08/19 22:06:03 stelian Exp $"; #endif /* not lint */ #ifdef __linux__ @@ -877,9 +877,9 @@ Exit(int status) static void proceed(int signo) { - caught++; if (ready) siglongjmp(jmpbuf, 1); + caught++; } void @@ -895,6 +895,9 @@ enslave(void) master = getpid(); { struct sigaction sa; + sa.sa_sigaction = NULL; + sigemptyset(&sa.sa_mask); + sa.sa_flags = 0; sa.sa_handler = dumpabort; sigaction(SIGTERM, &sa, NULL); /* Slave sends SIGTERM on dumpabort() */ sa.sa_handler = sigpipe; @@ -1081,6 +1084,7 @@ doslave(int cmd, int slave_number) if (wrote < 0) { (void) kill(master, SIGUSR1); sigemptyset(&sigset); + sigaddset(&sigset, SIGINT); for (;;) sigsuspend(&sigset); } else {