1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-24 01:15:29 +02:00

Patch from Thomas Fletcher to fix environment reading on win98

This commit is contained in:
Sebastien Marineau 2002-08-09 02:39:11 +00:00
parent b9ffb7a6dc
commit 0ddf06d9e6

View file

@ -28,9 +28,13 @@ public class EnvironmentReader {
rawVars = new Vector(32);
String command = "env";
InputStream in = null;
boolean check_ready = false;
try {
if (OS.indexOf("windows 9") > -1) {
command = "command.com /c set";
//The buffered stream doesn't always like windows 98
check_ready = true;
} else if ((OS.indexOf("nt") > -1) || (OS.indexOf("windows 2000") > -1)) {
command = "cmd.exe /c set";
}
@ -48,6 +52,9 @@ public class EnvironmentReader {
} else {
envVars.setProperty(line, "");
}
if(check_ready && br.ready() == false) {
break;
}
}
} catch (IOException e) {
} finally {