JDK-8211844 [aix] ProcessBuilder: Piping between created processes does not work.

Steve Groeger GROEGES at uk.ibm.com
Thu Dec 6 15:25:33 UTC 2018


Hi all, 

I have been investigating the issue 
https://bugs.openjdk.java.net/browse/JDK-8211844 raised by Goetz 
Lindenmaier which is related to the 
jdk/java/lang/ProcessBuilder/PipelineTest.java JTReg test failing on AIX. 
Having done some investigation I have a potential fix fore the issue:


diff -r 9501a7b59111 src/java.base/unix/classes/java/lang/ProcessImpl.java
--- a/src/java.base/unix/classes/java/lang/ProcessImpl.java     Mon Dec 03 
14:28:19 2018 +0300
+++ b/src/java.base/unix/classes/java/lang/ProcessImpl.java     Thu Dec 06 
15:01:03 2018 +0000
@@ -446,7 +446,7 @@
                         ProcessBuilder.NullOutputStream.INSTANCE :
                         new ProcessPipeOutputStream(fds[0]);

-                stdout = (fds[1] == -1) ?
+                stdout = (fds[1] == -1 || forceNullOutputStream) ?
                          ProcessBuilder.NullInputStream.INSTANCE :
                          new DeferredCloseProcessPipeInputStream(fds[1]);

I would appreciate any feedback please, and for someone to be a sponsor 
for this and to contributute it to OpenJDK.

Steve Groeger
IBM Runtime Technologies
Hursley, Winchester
Tel: (44) 1962 816911  Mobex: 279990  Mobile: 07718 517 129
Fax (44) 1962 816800
Lotus Notes: Steve Groeger/UK/IBM
Internet: groeges at uk.ibm.com

Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number 
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number 
741598. 
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/ppc-aix-port-dev/attachments/20181206/70e31c66/attachment.html>


More information about the ppc-aix-port-dev mailing list