[c++-pthreads] Re: pthread_cancel and EH: let's try this again

Peter Dimov pdimov at mmltd.net
Sat Jul 23 18:30:34 UTC 2005


Alexander Terekhov wrote:
> Peter Dimov wrote:
> [...]
>> I don't insist on this particular model. I'm in favor of a family of
>> models whose characteristic is no implicit cancel state manipulation
>> and conditional cancel delivery.
>>
>> The actual condition can be "no unfinished exception", but it can
>> also be "no uncaught exception", "no unfinished cancellation
>> exception", and so on.
>
> where the "finish" is manifested via enabling cancellation by the user
> code.

But the problem is with existing user code that doesn't reenable 
cancellation. The cancellation exception is swallowed by the catch-all 
clause, the request is lost, and the cancel state remains disabled.

As you can see, this leads to fixes that break catch(...) in a variety of 
creative ways.

> http://opengroup.org/austin/mailarchives/austin-review-l/msg01450.html

So it was _your_ idea. ;-) 




More information about the c++-pthreads mailing list