It looks like there is a clash between the management of the redirection of the IO
|
if (EntryPoint.verbose) { |
|
// Redirecting to given output stream |
|
if (EntryPoint.outPrintStream != null) { |
|
pb.redirectOutput(Redirect.PIPE); |
|
pb.redirectError(Redirect.PIPE); |
|
} else { |
|
// Redirecting to main process IO (System out/err) |
|
pb.inheritIO(); |
|
} |
|
} else { |
|
// Redirecting to null file is required to avoid thread deadlocks (when verbose |
|
// is disabled) |
|
pb.redirectOutput(File.createTempFile("test-runner-error", ".tmp")) |
|
.redirectErrorStream(true); |
|
} |
|
process = pb.start(); |
|
if (EntryPoint.verbose && EntryPoint.outPrintStream != null) { |
|
inheritIO(process.getInputStream(), EntryPoint.outPrintStream); |
|
inheritIO(process.getErrorStream(), EntryPoint.outPrintStream); |
|
} |
The condition EntryPoint.verbose && EntryPoint.outPrintStream != null is checked twice and has two different bodies.
pb.redirectOutput(Redirect.PIPE);
pb.redirectError(Redirect.PIPE);
vs
inheritIO(process.getInputStream(), EntryPoint.outPrintStream);
inheritIO(process.getErrorStream(), EntryPoint.outPrintStream);
It looks like there is a clash between the management of the redirection of the IO
test-runner/src/main/java/eu/stamp_project/testrunner/EntryPoint.java
Lines 750 to 769 in adb1c99
The condition
EntryPoint.verbose && EntryPoint.outPrintStream != nullis checked twice and has two different bodies.vs