On Saturday, November 26, 2011 10:57:09 am David Chisnall wrote: > Author: theraven > Date: Sat Nov 26 15:57:09 2011 > New Revision: 227999 > URL: http://svn.freebsd.org/changeset/base/227999 > > Log: > Return not-implemented from pthread_once and pthread_key_create, rather > than silently failing and returning success. > > Without this, code calls pthread_once(), receives a return value of > success, and thinks that the passed function has been called. > > Approved by: dim (mentor)
Hmmm, is this really the best fix? I really want pthread_once() to always work (see the hack I have to do with _once() in libc to workaround the fact that it doesn't now). The current behavior exists to appease libstdc++ which uses a silently failing pthread_once() to figure out if it is linked against working threads. If this is for libc++, can you provide some other way than abusing pthread_once() to determine this? Ideally it would be as smart as libc and use __isthreaded in some fastion. -- John Baldwin _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"