There is an error in the macro for pthread_cleanup_push. Right now it is #define pthread_cleanup_push(routine,arg) \ { struct _pthread_cleanup_buffer _buffer; \ _pthread_cleanup_push (&_buffer, (routine), (arg)); while it should be #define pthread_cleanup_push(routine,arg) \ { struct _pthread_cleanup_buffer _buffer; \ _pthread_cleanup_push (&_buffer, (routine), (arg)); } Note that it is currently missing a closing }
this is in what package?
I have no idea what package holds the headers for the system, I only know that my gentoo box has that problem on it and I've never touched the system headers before. Josh.
what version of glibc do you have installed? can you please paste the output of emerge info
* sys-libs/glibc Latest version available: 2.3.1-r4 Latest version installed: 2.3.1-r4 Size of downloaded files: 17,701 kB Homepage: http://www.gnu.org/software/libc/libc.html Description: GNU libc6 (also called glibc2) C library
This is not a bug, it is intentional feature of the header files, read the comments in pthread.h: pthread_cleanup_push and pthread_cleanup_pop are macros and must always be used in matching pairs at the same nesting level of braces. Thus pthread_cleanup_push opens a brace and pthread_cleanup_pop closes the brace, closing bug