#ifndef _NTTP_H
// winbase:WaitForThreadpoolTimerCallbacks
/**
* Waits for outstanding timer callbacks to complete and optionally cancels pending callbacks.
*
* \param[in,out] Timer A pointer to a TP_TIMER structure that defines the timer object.
* \param[in] CancelPendingCallbacks If TRUE, pending callbacks that have not started are canceled.
* \sa https://learn.microsoft.com/en-us/windows/win32/api/threadpoolapiset/nf-threadpoolapiset-waitforthreadpooltimercallbacks
*/
NTSYSAPI
VOID
NTAPI
TpWaitForTimer(
_Inout_ PTP_TIMER Timer,
_In_ LOGICAL CancelPendingCallbacks
);
View code on GitHubWaits for outstanding timer callbacks to complete and optionally cancels pending callbacks that have not yet started to execute.
WaitForThreadpoolTimerCallbacks maps directly to this function.