4.2bsd, signals, system calls
Morris Jones
mojo at kepler.UUCP
Tue Nov 26 11:52:53 AEST 1985
I've been porting the recently posted "chat" program to 4.2bsd, and
as we all know, 4.2 does not terminate a system call on a signal.
I'm running into the problem that people who ^C (intr) out of the
program are sometimes left with a process that runs forever, despite
hanging up, quit signals, etc. Kill -9 works.
My theory is that the intr occurs during a getchar(), during a read
from the console, and the read is sticking around refusing to die.
If my trap for intr doesn't do an exit(), but merely sets a flag and
returns, what is the best way for me to force the getchar() to
terminate and return to the program?
--
Mojo
... Morris Jones, MicroPro Product Development
{ptsfa,hplabs,glacier,lll-crg}!well!micropro!kepler!mojo
{ucbvax,decwrl}!dual!micropro!kepler!mojo
More information about the Comp.unix
mailing list