windows-nt/Source/XPSP1/NT/windows/netdde/incs/critsec.h
2020-09-26 16:20:57 +08:00

7 lines
334 B
C

extern CRITICAL_SECTION csNetDde;
#define EnterCrit() (EnterCriticalSection(&csNetDde))
#define LeaveCrit() (LeaveCriticalSection(&csNetDde))
#define CheckCritIn() assert((HANDLE)(ULONG_PTR)GetCurrentThreadId() == csNetDde.OwningThread)
#define CheckCritOut() assert((HANDLE)(ULONG_PTR)GetCurrentThreadId() != csNetDde.OwningThread)