Subj : Re: pthread_sigmask in single thread application To : comp.programming.threads From : Giancarlo Niccolai Date : Wed Jan 05 2005 10:59 am Patrick TJ McPhee wrote: > In article , > Giancarlo Niccolai wrote: > > % In a multithread program, the best choice is probably that of dedicate > one % thread to receive all signals > > I agree with this. > > % 3) in the monitor thread: accept all the signals you wish to handle. > % 4) wait forever on a condition variable that will never be signaled... > > But not this. It's much simpler to leave the signals blocked and use > sigwait(). Uhm, sometimes the obvious solution is what you are missing ;-). Yes, sigwait is the best thing to do, probably does it all much better. Gian. .