--- a/jdk/src/java.base/unix/classes/java/lang/ProcessImpl.java Fri Jun 17 10:08:39 2016 -0700
+++ b/jdk/src/java.base/unix/classes/java/lang/ProcessImpl.java Fri Jun 17 15:57:28 2016 -0400
@@ -649,7 +649,7 @@
private final Object closeLock = new Object();
ProcessPipeInputStream(int fd) {
- super(new FileInputStream(newFileDescriptor(fd)));
+ super(new PipeInputStream(newFileDescriptor(fd)));
}
private static byte[] drainInputStream(InputStream in)
throws IOException {
@@ -725,8 +725,7 @@
// behavior. By deferring the close we allow any pending reads to see -1
// (EOF) as they did before.
//
- private static class DeferredCloseInputStream extends FileInputStream
- {
+ private static class DeferredCloseInputStream extends PipeInputStream {
DeferredCloseInputStream(FileDescriptor fd) {
super(fd);
}
@@ -848,7 +847,7 @@
private boolean closePending = false;
DeferredCloseProcessPipeInputStream(int fd) {
- super(new FileInputStream(newFileDescriptor(fd)));
+ super(new PipeInputStream(newFileDescriptor(fd)));
}
private InputStream drainInputStream(InputStream in)