| 57 | } |
| 58 | |
| 59 | void 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 | |
| 78 | void BoxedWineCondition::signalAll() { |
| 79 | if (parentCount) { |
nothing calls this directly
no test coverage detected