POSIX清理函数的调用时机:
调用pthread_exit()时,会调用清理函数;通过return返回的线程不会调用。
被别的线程取消的时候,会调用。
pthread_cleanup_pop()参数为非零时,会调用。