Why am I using MIT-Pthreads? Because all the alternatives seem to have
very low level problems. PTL2 has a locking problem of some sort that I
cannot track down, and the author insists that
lock = PTHREAD_MUTEX_INIT;
is always to be legal, so he uses a pointer for locks. This means
pthread_lock() can break in out of memory situations, and therefore so
can pthread_once(), and if you're using that to protect logging, and you
need to report a memory depletion, you're screwed.
--Michael