In CommandLineUtils, the call() method calls waitUntilDone() on inputFeeder, outputPumper, and errorPumper sequentially (lines 298-303). If the first call throws (e.g., InterruptedException), the remaining pumpers are never waited on, leaving their threads potentially running.
The commented-out code above (lines 277-297) shows the original author intended a try-finally chain, but it was disabled.
Fix: wrap the calls in a try-finally to ensure all pumpers are waited on even when an earlier one throws.
In
CommandLineUtils, thecall()method callswaitUntilDone()oninputFeeder,outputPumper, anderrorPumpersequentially (lines 298-303). If the first call throws (e.g.,InterruptedException), the remaining pumpers are never waited on, leaving their threads potentially running.The commented-out code above (lines 277-297) shows the original author intended a try-finally chain, but it was disabled.
Fix: wrap the calls in a try-finally to ensure all pumpers are waited on even when an earlier one throws.