diff --git a/WHATSNEW b/WHATSNEW index 794ace806..f744295da 100644 --- a/WHATSNEW +++ b/WHATSNEW @@ -29,6 +29,9 @@ Fixed bugs: * did not create properties for empty leaf elements. Bugzilla report 26286. +* UnknownElement.maybeConfigure always configured. + Bugzilla report 40641. + Other changes: -------------- diff --git a/src/main/org/apache/tools/ant/UnknownElement.java b/src/main/org/apache/tools/ant/UnknownElement.java index 31011c3d3..9f87109cd 100644 --- a/src/main/org/apache/tools/ant/UnknownElement.java +++ b/src/main/org/apache/tools/ant/UnknownElement.java @@ -152,10 +152,9 @@ public class UnknownElement extends Task { * @exception BuildException if the configuration fails */ public void maybeConfigure() throws BuildException { - //ProjectComponentHelper helper=ProjectComponentHelper.getProjectComponentHelper(); - //realThing = helper.createProjectComponent( this, getProject(), null, - // this.getTag()); - + if (realThing != null) { + return; + } configure(makeObject(this, getWrapper())); }