Skip to content

Commit 9cbb9fb

Browse files
committed
Drop isAlive
1 parent fc6b202 commit 9cbb9fb

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

impl/maven-executor/src/main/java/org/apache/maven/cling/executor/forked/ForkedMavenExecutor.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ protected Consumer<Process> wrapRequestStandardStreams(ExecutorRequest executorR
109109
Thread pump = new Thread(() -> {
110110
try {
111111
int c;
112-
while (p.isAlive() && (c = p.getInputStream().read()) != -1) {
112+
while ((c = p.getInputStream().read()) != -1) {
113113
stdout.write(c);
114114
}
115115
stdout.flush();
@@ -125,7 +125,7 @@ protected Consumer<Process> wrapRequestStandardStreams(ExecutorRequest executorR
125125
Thread pump = new Thread(() -> {
126126
try {
127127
int c;
128-
while (p.isAlive() && (c = p.getErrorStream().read()) != -1) {
128+
while ((c = p.getErrorStream().read()) != -1) {
129129
stderr.write(c);
130130
}
131131
stderr.flush();
@@ -141,7 +141,7 @@ protected Consumer<Process> wrapRequestStandardStreams(ExecutorRequest executorR
141141
Thread pump = new Thread(() -> {
142142
try {
143143
int c;
144-
while (p.isAlive() && (c = stdin.read()) != -1) {
144+
while ((c = stdin.read()) != -1) {
145145
p.getOutputStream().write(c);
146146
}
147147
p.getOutputStream().flush();

0 commit comments

Comments
 (0)