[quagga-dev 1364] Re: signal handling breaks gdb on NetBSD - fixed in CVS
paul at clubi.ie
Thu Jul 15 15:46:20 BST 2004
On Thu, 15 Jul 2004, Greg Troxel wrote:
> That's what I meant - the ordering of the operations - test, then
> clear and run, is critical, so that there is no chance of a signal
> handler not getting run.
> I'm probably being overly paranoid - I like to explain why things
> are safe fo the code reviewer.
No, you're not. I had actually initially put the clear of the global
caught /below/ the loop through the array of quagga_signal_t's.
> But, IMHO it's a reasonable expectation that shutdown at least
> commence 'immediately' upen receipt of SIGTERM.
define immediately - the whole point of sigevent is to _not_ do lots
of stuff in signal context. :)
> But yes, I guess we could change it to run the non-signal-context
> 'signal handlers' on EINTR. We dont need any master flag in that case
> btw, EINTR from select() should be enough to tell us a signal occured
> Good point - that sounds like a good plan.
ah, we'll still need a timer, unless we tell users to be very careful
and use to strace to ensure they only send signals while daemons are
sleeping in select ;) So we can keep the global flag.
i'll have a think about cleanest way to do this.
Paul Jakma paul at clubi.ie paul at jakma.org Key ID: 64A2FF6A
warning: do not ever send email to spam at dishone.st
your process is not ISO 9000 compliant
More information about the Quagga-dev