ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From peter reilly <peter.rei...@corvil.com>
Subject Re: cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Ant.java
Date Wed, 10 Sep 2003 13:40:47 GMT
This reminds me of another bug I forgot
to report.

If <ant/> is called without setting target,
the default target is called. If there is
no default target, the "" target is called.
This means that the top-level tasks are
called twice.

Example:

hello.xml
<project>
  <echo>Hello world</echo>
</project>

build.xml
...
   <ant antfile="hello.xml"/>


The solution is not to execute the target if
the target is "".


On Wednesday 10 September 2003 14:17, bodewig@apache.org wrote:
> bodewig     2003/09/10 06:17:00
>
>   Modified:    src/main/org/apache/tools/ant/taskdefs Ant.java
>   Log:
>   It is legal to omit the target attribute in <ant>, don't die with a NPE
>

Mime
View raw message