Commit 92e65e1
fix: use wait -n to reap zombie subshells in parallel job pool
kill -0 returns success for zombie processes (completed but not yet reaped).
Without wait -n, _PIDS never shrinks below PARALLEL_TASKS after all initial
slots fill — remaining tasks never get submitted.
wait -n on the PIDS list blocks until one child completes and reaps it,
allowing kill -0 to correctly detect the freed slot.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 90eae1a commit 92e65e1
1 file changed
+6
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
307 | 307 | | |
308 | 308 | | |
309 | 309 | | |
310 | | - | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
311 | 313 | | |
312 | 314 | | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
313 | 318 | | |
314 | 319 | | |
315 | 320 | | |
316 | 321 | | |
317 | 322 | | |
318 | | - | |
319 | 323 | | |
320 | 324 | | |
321 | 325 | | |
| |||
0 commit comments