Re: A signal fairy tale

From: Christopher Smith (x@xman.org)
Date: Wed Jun 27 2001 - 13:16:08 EST


--On Wednesday, June 27, 2001 11:18:28 +0200 Jamie Lokier
<lk@tantalophile.demon.co.uk> wrote:
> Btw, this functionality is already available using sigaction(). Just
> search for a signal whose handler is SIG_DFL. If you then block that
> signal before changing, checking the result, and unblocking the signal,
> you can avoid race conditions too. (This is what my programs do).

It's more than whether a signal is blocked or not, unfortunately. Lots of
applications will invoke sigwaitinfo() on whatever the current signal mask
is, which means you can't rely on sigaction to solve your problems. :-(

--Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Jun 30 2001 - 21:00:17 EST