The constructor calls the Win32 function InitializeCriticalSection, which initializes the critical section object contained in the m_sec data member. The destructor calls DeleteCriticalSection, which releases all system resources used by the critical section object.
void CComAutoCriticalSection( );
| Header file: | Atlbase.h |
| Platforms: | |
| Versions: | 2.0 and later |
| Complete documentation: | Visual C++ documentation |
This method calls the Win32 function EnterCriticalSection, which waits until the thread can take ownership of the critical section object contained in the m_sec data member.
void Lock( );
| Header file: | Atlbase.h |
| Platforms: | |
| Versions: | 2.0 and later |
| Complete documentation: | Visual C++ documentation |
CComAutoCriticalSection Overview, CComAutoCriticalSection Methods