Addresses a possible race condition for which, from the moment living subprocesses are listed and killed, new subprocesses could be spawned, which would never be killed.
This solution provides a remedy so long as this race condition doesn't occur 10 times in a row. Note that it does not fundamentally solve the problem, but even if subprocesses might still be leaked, the leakage rate should be acceptable.
Addresses a possible race condition for which, from the moment living subprocesses are listed and killed, new subprocesses could be spawned, which would never be killed.
This solution provides a remedy so long as this race condition doesn't occur 10 times in a row. Note that it does not fundamentally solve the problem, but even if subprocesses might still be leaked, the leakage rate should be acceptable.