Subject: Re: Cryptic behavior...
To: der Mouse <mouse@Rodents.Montreal.QC.CA>
From: Erik E. Fair <>
List: current-users
Date: 03/13/1998 02:00:37
Lo, many years ago, we had an Onyx Z8002 system running Onix in the
basement of Evans Hall at UCB. We hacked that system into a semblance of
BSD from what was a V7 base. We added, among other things, job control. Of
course, there were programs that fiddled tty state which we didn't have
source to (or couldn't get to compile - my memory of the details is vague).

Our semi-solution to this problem was to change the shells in much the same
way as der Mouse suggests, except that our changes had the shells (just sh
and csh in those days) keeping track of tty state always. Then, it examined
the return code from exiting children - if the child exited normally, the
shell would accept the new tty state. If the child exited abnormally, the
shell would restore previous tty state. Presto! Never any tty state
screwups, and "stty" works as expected.

It was really nice.

	Erik <>