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

Re: localtraps and signal handling on NetBSD

On Mon, May 09, 2005 at 10:32:28AM +0100, Peter Stephenson wrote:
> Vincent Stemen wrote:
> > I was just wondering if you are planning to do any further work on the
> > signal/localtrap code.
> As far as I've followed the problems, they're mostly system specific.
> I'm sure there's more that can be done but I'm not really clear what.
> I'm not a great expert on signals anyway (traps are a  little
> different).
> pws

Ok.  For now, I found a not so clean work around for the code I am
working on, that would not necessarily work in other situations.  

If you come up with any other ideas to try, I am willing to test for
you and assist in any way I can.

I did notice in the zsh source that it sets an intrap flag once a
signal has been received, which apparently causes it to treat the next
signal special by queuing it and waiting until it exits the signal
handler before processing it.

I have an idea, that might not be to difficult to implement, that I
think would solve the problem, unless you know of other problems it
would create.

If, inside the signal handler, I execute the trap statement on the
same signal, turn off the intrap status because the signal is now

I don't know the zsh source well enough to be sure where to make that
change, but from initial browsing, it looks like it might be easy to

Does that sound like something you would be willing to try, and send
me a patch to test on NetBSD?

Vincent Stemen
Avoid the VeriSign/Network Solutions domain registration trap!
Read how Network Solutions (NSI) was involved in stealing our domain name.

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