MCPcopy Create free account
hub / github.com/ddnet/ddnet / sphore_wait

Function sphore_wait

src/base/sphore.cpp:30–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28 dbg_assert(*sem != nullptr, "CreateSemaphoreW failure");
29}
30void sphore_wait(SEMAPHORE *sem)
31{
32 dbg_assert(WaitForSingleObject((HANDLE)*sem, INFINITE) == WAIT_OBJECT_0, "WaitForSingleObject failure");
33}
34void sphore_signal(SEMAPHORE *sem)
35{
36 dbg_assert(ReleaseSemaphore((HANDLE)*sem, 1, nullptr), "ReleaseSemaphore failure");

Callers 6

RunLoopMethod · 0.85
TEST_FFunction · 0.85
TESTFunction · 0.85
SemaphoreThreadFunction · 0.85
aio_threadFunction · 0.85
WaitMethod · 0.85

Calls

no outgoing calls

Tested by 3

TEST_FFunction · 0.68
TESTFunction · 0.68
SemaphoreThreadFunction · 0.68