MCPcopy Create free account
hub / github.com/danoon2/Boxedwine / signal

Method signal

source/util/synchronization.cpp:59–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57}
58
59void BoxedWineCondition::signal() {
60 if (parentCount) {
61 for (int i = 0; i < MAX_PARENTS; i++) {
62 std::shared_ptr<BoxedWineCondition> parent;
63
64 {
65 const std::lock_guard<std::mutex> lock(parentsMutex);
66 parent = parents[i].lock();
67 }
68 if (parent) {
69 BOXEDWINE_CRITICAL_SECTION_WITH_CONDITION(parent);
70 parent->signal();
71 break;
72 }
73 }
74 }
75 this->c.notify_one();
76}
77
78void BoxedWineCondition::signalAll() {
79 if (parentCount) {

Callers

nothing calls this directly

Calls 2

signalThreadMethod · 0.95
lockMethod · 0.45

Tested by

no test coverage detected