MCPcopy Create free account
hub / github.com/cutelyst/cutelyst / decreaseWorkerRespawn

Method decreaseWorkerRespawn

Cutelyst/Server/unixfork.cpp:155–168  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

153}
154
155void UnixFork::decreaseWorkerRespawn()
156{
157 int missingRespawn = 0;
158 for (const auto &[key, value] : m_childs.asKeyValueRange()) {
159 if (value.respawn > 0) {
160 --value.respawn;
161 missingRespawn += value.respawn;
162 }
163 }
164
165 if (missingRespawn) {
166 QTimer::singleShot(std::chrono::seconds{1}, this, &UnixFork::decreaseWorkerRespawn);
167 }
168}
169
170void UnixFork::killChild()
171{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected