Browse Source

tabs to spaces

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@270009 13f79535-47bb-0310-9956-ffa450edef68
master
Steve Loughran 23 years ago
parent
commit
de4ef1dc99
1 changed files with 12 additions and 12 deletions
  1. +12
    -12
      src/main/org/apache/tools/ant/types/CommandlineJava.java

+ 12
- 12
src/main/org/apache/tools/ant/types/CommandlineJava.java View File

@@ -345,26 +345,26 @@ public class CommandlineJava implements Cloneable {
}

private String getJavaExecutableName() {
// This is the most common extension case - exe for windows and OS/2,
// This is the most common extension case - exe for windows and OS/2,
// nothing for *nix.
String extension = Os.isFamily("dos") ? ".exe" : "";
String extension = Os.isFamily("dos") ? ".exe" : "";

// Look for java in the java.home/../bin directory. Unfortunately
// on Windows java.home doesn't always refer to the correct location,
// so we need to fall back to assuming java is somewhere on the
// PATH.
java.io.File jExecutable =
// Look for java in the java.home/../bin directory. Unfortunately
// on Windows java.home doesn't always refer to the correct location,
// so we need to fall back to assuming java is somewhere on the
// PATH.
java.io.File jExecutable =
new java.io.File(System.getProperty("java.home") +
"/../bin/java" + extension );

if (jExecutable.exists() && !Os.isFamily("netware")) {
if (jExecutable.exists() && !Os.isFamily("netware")) {
// NetWare may have a "java" in that directory, but 99% of
// the time, you don't want to execute it -- Jeff Tulley
// <JTULLEY@novell.com>
return jExecutable.getAbsolutePath();
} else {
return "java";
}
return jExecutable.getAbsolutePath();
} else {
return "java";
}
}
}

Loading…
Cancel
Save