diff --git a/WHATSNEW b/WHATSNEW index eae61fbb7..94b43d0d5 100644 --- a/WHATSNEW +++ b/WHATSNEW @@ -41,6 +41,9 @@ Fixed bugs: can now handle files as long as there is enough disk space available. +* Commandline.describeCommand() methods would attempt to describe + arguments even when none, other than the executable name, were present. + Other changes: -------------- diff --git a/src/main/org/apache/tools/ant/types/Commandline.java b/src/main/org/apache/tools/ant/types/Commandline.java index f8167502a..041dfe6a4 100644 --- a/src/main/org/apache/tools/ant/types/Commandline.java +++ b/src/main/org/apache/tools/ant/types/Commandline.java @@ -554,7 +554,7 @@ public class Commandline implements Cloneable { StringBuffer buf = new StringBuffer("Executing \'"); buf.append(args[0]); buf.append("\'"); - if (args.length > 0) { + if (args.length > 1) { buf.append(" with "); buf.append(describeArguments(args, 1)); } else {