mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Initialize file descriptors with -1 in case of exec_detached, related to 345164
This commit is contained in:
parent
19370c7dcf
commit
fe42af7abe
1 changed files with 4 additions and 1 deletions
|
@ -61,7 +61,7 @@ public class Spawner extends Process {
|
|||
|
||||
int pid = 0;
|
||||
int status;
|
||||
int[] fChannels = new int[3];
|
||||
final int[] fChannels = new int[3];
|
||||
boolean isDone;
|
||||
OutputStream out;
|
||||
InputStream in;
|
||||
|
@ -400,6 +400,9 @@ public class Spawner extends Process {
|
|||
if (pid == -1) {
|
||||
throw new IOException("Exec error"); //$NON-NLS-1$
|
||||
}
|
||||
fChannels[0] = -1;
|
||||
fChannels[1] = -1;
|
||||
fChannels[2] = -1;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue