[net.bugs.4bsd] CSH -- stopping job in SOURCE'd file

idallen@watmath.UUCP (11/18/84)

> From ron@brl-tgr.ARPA (Ron Natalie <ron>) Thu Nov 15 20:06:27 1984
> > Not only will C be thrown away if you stop B in the following:
> > 
> >     a ; b ; c
> > 
> > ...but if you stop a job executing from in a SOURCE'd file, the rest
> > of the file gets thrown away too.  This can be really annoying if
> > you read your mail or news in your .login, and stop either...
> >         -IAN!  (Ian! D. Allen)      University of Waterloo
> It is totally understandable that this happens.  If you think about it,
> it has to.  Berkeley Job control doesn't provide for the switching of
> input streams.
> If you need a method of thinking about it, just remember that shell
> input is dealt with upon a stop as if an "interrupt" had occured.

It doesn't have to.  I fixed it.  Stopping a job in a SOURCE'd file
just stops the job.  The shell continues with the next command in the
file.  My fix also means " a ; b ; c " behaves as documented; stopping
process B lets process C start.
-- 
        -IAN!  (Ian! D. Allen)      University of Waterloo

mark@elsie.UUCP (Mark J. Miller) (11/20/84)

> 
> It doesn't have to.  I fixed it.  Stopping a job in a SOURCE'd file
> just stops the job.  The shell continues with the next command in the
> file.  My fix also means " a ; b ; c " behaves as documented; stopping
> process B lets process C start.
> -- 
>         -IAN!  (Ian! D. Allen)      University of Waterloo

That's a fix I don't want. I've often used ^Z to zap a series of type-ahead
jobs, when that was what I wanted it to do. Especially useful if one of those
jobs contains an error. You can use ^Z; fg to erase and start over again.
That's the trouble, isn't it. One persons bug is another's feature.

					--elsie!mark

-- 
Mark J. Miller
NIH/NCI/DCE/LEC
UUCP:	decvax!harpo!seismo!elsie!mark
Phone:	(301) 496-5688

ron@brl-tgr.ARPA (Ron Natalie <ron>) (11/20/84)

> My fix also means " a ; b ; c " behaves as documented; stopping
> process B lets process C start.
> -- 
>         -IAN!  (Ian! D. Allen)      University of Waterloo

Great, Berkeley documents something as being a bug, later fixes it, and
some person goes back and changes it back.  In my opinion there are only
two correct modes of operation for stopping a ; b ; c.

Either the whole line should be stopped as a unit, or when b is stopped
c should not be run.

-Ron