#include <cafe/os.h> typedef void (*OSThreadCleanupCallback)(void* thread, void* stackEnd); OSThreadCleanupCallback OSSetThreadCleanupCallback (OSThread* thread, OSThreadCleanupCallback callback);
|thread||Pointer to thread.|
|callback||Pointer to callback.|
The function pointer to the previously set callback.
Registers the callback to run immediately before the thread terminates. The callback runs right before the thread terminates using the thread stack. The thread structure and thread stack end (stack base - stack size) pointer are provided as callback arguments.
2013/05/08 Automated cleanup pass.
2012/08/01 Cleanup pass.
2011/11/28 Initial version.