#include <oskit/threads/pthread.h>void pthread_cleanup_push(void (*routine)(void *), void *arg);
Push a cancellation cleanup handler routine onto the calling thread's cancellation cleanup stack. When requested, the cleanup routine will be popped from the cancellation stack, and invoked with the argument arg.
- routine
- The cleanup handler routine.
- arg
- The argument to pass to the cleanup handler routine.
pthread_cancel, pthread_cleaup_pop