Пример #1
0
/*++
Function :
    MsgBoxInitialize

    Initialize the critical sections.

Return value:
    TRUE if initialize succeeded
    FALSE otherwise

--*/
BOOL
MsgBoxInitialize( void )
{
    TRACE( "Initialising the critical section.\n" );
    InternalInitializeCriticalSection(&msgbox_critsec);

    return TRUE;
}
Пример #2
0
        CSynchCache(int iMaxDepth = MaxDepth) :             
            m_pHead(NULL),
            m_iDepth(0),
            m_iMaxDepth(iMaxDepth)
#ifdef _DEBUG
            ,m_iMaxTrackedDepth(0)
#endif
        { 
            InternalInitializeCriticalSection(&m_cs);
            if (m_iMaxDepth < 0)
            {
                m_iMaxDepth = 0;
            }
        }