8238366: CTW runner closes standard output on exit

Reviewed-by: adinn, iignatyev
This commit is contained in:
Aleksey Shipilev 2020-02-10 06:18:10 +01:00
parent ac69c7894d
commit f1a2c6019e

View File

@ -99,9 +99,11 @@ public class CompileTheWorld {
} catch (Throwable t){
t.printStackTrace(ERR);
} finally {
try {
OUT.close();
} catch (Throwable ignore) {
if (OUT != System.out) {
try {
OUT.close();
} catch (Throwable ignore) {
}
}
// <clinit> might have started new threads
System.exit(passed ? 0 : 1);