MCPcopy Create free account
hub / github.com/OpenPathGuidingLibrary/openpgl / lock

Method lock

third-party/embreeSrc/common/sys/mutex.cpp:16–16  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

14 MutexSys::MutexSys() { mutex = new CRITICAL_SECTION; InitializeCriticalSection((CRITICAL_SECTION*)mutex); }
15 MutexSys::~MutexSys() { DeleteCriticalSection((CRITICAL_SECTION*)mutex); delete (CRITICAL_SECTION*)mutex; }
16 void MutexSys::lock() { EnterCriticalSection((CRITICAL_SECTION*)mutex); }
17 bool MutexSys::try_lock() { return TryEnterCriticalSection((CRITICAL_SECTION*)mutex) != 0; }
18 void MutexSys::unlock() { LeaveCriticalSection((CRITICAL_SECTION*)mutex); }
19}

Callers 1

waitMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected