With FreeBSD 8.0 it seems like you can't block pending but undelivered signals

Richard Sharpe realrichardsharpe at gmail.com
Tue Jan 8 12:44:50 MST 2013


On Tue, Jan 8, 2013 at 11:25 AM, Jeremy Allison <jra at samba.org> wrote:
> On Tue, Jan 08, 2013 at 11:15:39AM -0800, Richard Sharpe wrote:
>>
>> OK, it seems that it is not so bad. Based on a response I got from the
>> FreeBSD Hackers mailing list, and some digging, I think the answer is:
>>
>>             sigaddset(&((ucontext_t *)uctx)->uc_sigmask, sig);
>>
>> I will try this soon and get back to you.
>>
>> >From here: http://stackoverflow.com/questions/5531006/returning-from-a-signal-handler-and-leaving-signal-masked
>
> Oh God that is a *horrible* hack :-).

As much as you think it is ugly, it works ... I guess ugly is sometimes good :-)

-- 
Regards,
Richard Sharpe
(何以解憂?唯有杜康。--曹操)


More information about the samba-technical mailing list