On Mon, Jan 14, 2013 at 09:55:38PM +0100, Antti Kantee wrote: >Hi, > >Calling pthread_exit() at the end of a routine marked noreturn produces >a compiler warning/error on cygwin: > >error: 'noreturn' function does return > >Is it possible to add the attribute to the cygwin pthread.h: > >--- pthread.h.orig 2012-10-19 14:40:13.000000000 +0200 >+++ pthread.h 2013-01-14 21:40:00.018198900 +0100 >@@ -137,7 +137,7 @@ > void *(*)(void *), void *); > int pthread_detach (pthread_t); > int pthread_equal (pthread_t, pthread_t); >-void pthread_exit (void *); >+void pthread_exit (void *) __attribute__((__noreturn__)); > int pthread_getcpuclockid (pthread_t, clockid_t *); > int pthread_getschedparam (pthread_t, int *, struct sched_param *); > void *pthread_getspecific (pthread_key_t);
I added a ChangeLog entry and checked this in. Thanks for the patch. cgf -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple