Email List: Xaustin-group-lX
[All Lists]

RE: XSH/XRAT conflict over cancellation points

To: "'Dave Butenhof'" <yyyyyyyyyyyyyy@xxxxxx>, yyyyyyyyyyyyyy@xxxxxxxxxxxxx
Subject: RE: XSH/XRAT conflict over cancellation points
From: Schwarz Konrad <yyyyyyyyyyyyyy@xxxxxxxxxxx>
Date: Fri, 21 May 2004 09:53:15 +0200
> >int i;
> >int fd = open ("/dev/null", O_RDONLY);
> >char b [256];
> >
> >pthread_cleanup_push (my_handler, &i);
> >pthread_cancel (pthread_self());
> >i = 0;
> >read (fd, b, sizeof b);
> >i = 1;
> >pthread_testcancel();
> >  
> >
> (Actually, it may see neither, because my_handler is a 
> separate routine 
> that's probably invoked via something like an exception handler or 
> longjmp, and 'i' is a local variable that's not even volatile. ;-) )

It doesn't say that in the standard!  At least, I can't find it on
http://www.opengroup.org/onlinepubs/009695399/functions/pthread_cleanup_pop.
html nor in
http://www.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_09.html.
Should that be filed as a defect?

Regards,
Konrad Schwarz

<Prev in Thread] Current Thread [Next in Thread>