Browse Source

Revert logic that performs the <os family="win9x"/> check from "I know

all that are not win9x" to "I know all thar are win9x".

Note that the list is as authoritative, complete and real-world-tested
as my knowledge on said platform. ;-)

PR: 16611


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@274641 13f79535-47bb-0310-9956-ffa450edef68
master
Stefan Bodewig 22 years ago
parent
commit
c5e1c21947
1 changed files with 4 additions and 14 deletions
  1. +4
    -14
      src/main/org/apache/tools/ant/taskdefs/condition/Os.java

+ 4
- 14
src/main/org/apache/tools/ant/taskdefs/condition/Os.java View File

@@ -222,20 +222,10 @@ public class Os implements Condition {
&& (!isFamily("mac") || osName.endsWith("x"));
} else if (family.equals("win9x")) {
isFamily = isFamily("windows") &&
/*
* FIXME
*
* Need a better way to know which one runs CMD.EXE
* and wich COMMAND.COM.
*
* If we use a fixed list of names, we should rather
* use one for all win9x flavors as it is supposed to
* be a final list.
*/
!(osName.indexOf("nt") >= 0 ||
osName.indexOf("2000") >= 0 ||
osName.indexOf("2003") >= 0 ||
osName.indexOf("xp") >= 0);
(osName.indexOf("95") >= 0 ||
osName.indexOf("98") >= 0 ||
osName.indexOf("me") >= 0 ||
osName.indexOf("ce") >= 0);
} else if (family.equals("z/os")) {
isFamily = osName.indexOf("z/os") > -1
|| osName.indexOf("os/390") > -1;


Loading…
Cancel
Save