K 10 svn:author V 7 davidxu K 8 svn:date V 27 2010-08-17T02:50:12.782708Z K 7 svn:log V 526 Tweak code a bit to be POSIX compatible, when a cancellation request is acted upon, or when a thread calls pthread_exit(), the thread first disables cancellation by setting its cancelability state to PTHREAD_CANCEL_DISABLE and its cancelability type to PTHREAD_CANCEL_DEFERRED. The cancelability state remains set to PTHREAD_CANCEL_DISABLE until the thread has terminated. It has no effect if a cancellation cleanup handler or thread-specific data destructor routine changes the cancelability state to PTHREAD_CANCEL_ENABLE. END