Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site wateng.UUCP Path: utzoo!watmath!wateng!ksbszabo From: ksbszabo@wateng.UUCP (Kevin Szabo) Newsgroups: net.sources.bugs Subject: DIRED (distributed months ago) goes into infinite loop with SIGTSTP Message-ID: <1912@wateng.UUCP> Date: Fri, 25-Jan-85 18:13:35 EST Article-I.D.: wateng.1912 Posted: Fri Jan 25 18:13:35 1985 Date-Received: Tue, 29-Jan-85 05:41:05 EST Distribution: net Organization: VLSI Group, U of Waterloo Lines: 31 It seems that there is a bit of a race condition when the signal catcher redefines what to do with the signal and sends the signal to itself. For the 4.2 version I changed the signal it sends to be the non-catchable SIGSTOP. Only four lines have been added but I'll send the whole routine so you can see the context. Sorry, you can't use this with PATCH since I editted the original (yes, dangerous). Kevin onctlz () { curxy (0, Tscrlen); ceol (0,Tscrlen); unsetdpy(); signal(SIGTSTP,SIG_DFL); #ifdef V4P2 kill(0,SIGSTOP); /*re-send ^z, This one can't be caught. ksbszabo */ #else kill(0,SIGTSTP); /*re-send ^z */ #endif signal(SIGTSTP,onctlz); /* wake up here ... */ setdpy(); blank(); showscreen(); if (!intype) telluser(""); else { curxy (0, Tscrlen); ceol (0,Tscrlen); } } -- Kevin Szabo watmath!wateng!ksbszabo (U of Waterloo VLSI Group, Waterloo Ont.)