GO-10265 ensure EOF sent after copying stream from input file

GitOrigin-RevId: ea80f6a24390d7027864f248019f55a4d80893af
This commit is contained in:
Artem Khvastunov
2021-01-08 14:19:55 +00:00
committed by intellij-monorepo-bot
parent cf86cfc644
commit b6078b77f4
@@ -1,4 +1,4 @@
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2021 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.execution.process;
import com.intellij.diagnostic.LoadingState;
@@ -27,10 +27,8 @@ import org.jetbrains.annotations.Nullable;
import java.io.File;
import java.io.InputStream;
import java.nio.charset.Charset;
import java.util.Collections;
import java.util.HashSet;
import java.util.Set;
import java.util.concurrent.ConcurrentHashMap;
public class OSProcessHandler extends BaseOSProcessHandler {
private static final Logger LOG = Logger.getInstance(OSProcessHandler.class);
@@ -270,6 +268,10 @@ public class OSProcessHandler extends BaseOSProcessHandler {
}
}
public boolean hasPty() {
return myHasPty;
}
/**
* <p>In case of PTY this process handler will use blocking read because {@link InputStream#available()} doesn't work for Pty4j, and there
* is no reason to "disconnect" leaving PTY alive. See {@link BaseDataReader.SleepingPolicy} for more info.</p>