Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: job control



Peter Stephenson wrote:

> I was just trying to put together some tests for job control.  I had
> problems with this:
> 
> while true; do sed -e 's/foo/bar/' nosuchfile >/dev/null; done
> 
> I'm not quite sure what's going on, but it takes a long time to kill or
> suspend.  You can see lots of ^C's and error messages go sailing by until
> eventually it stops.  It works much more reliably when operating on a file
> that does exist.  That sort of suggests the problem happens when zsh,
> rather than sed, gets the signal.  I had it inside a function to begin
> with, but I think the problem was the same one.
> 
> Hitting ^Z is worse, since it still takes a long time, but when it
> eventually works the whole thing freezes

Damn. ^C works without problems for me (both on this DEC box here and
on the Linux-Laptop). ^Z *is* a problem for us since we can stop only
if you hit one of those sed's with the ^Z between the eyes -- only
then can we find out that someone tried to suspend the loop.
However, this works for me, too: once I've managed to suspend the loop 
I can cleanly fg it, ^C it, and so on.

Bye
 Sven


--
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



Messages sorted by: Reverse Date, Date, Thread, Author