You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by pe...@apache.org on 2006/10/05 23:48:50 UTC

svn commit: r453401 - in /ant/core/trunk: WHATSNEW docs/manual/CoreTasks/import.html src/main/org/apache/tools/ant/helper/ProjectHelper2.java

Author: peterreilly
Date: Thu Oct  5 14:48:49 2006
New Revision: 453401

URL: http://svn.apache.org/viewvc?view=rev&rev=453401
Log:
Do not set ant.file.{projectname} when the project name
is not set in the <project> tag. (as discussed)
Bugzilla report: 39920


Modified:
    ant/core/trunk/WHATSNEW
    ant/core/trunk/docs/manual/CoreTasks/import.html
    ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java

Modified: ant/core/trunk/WHATSNEW
URL: http://svn.apache.org/viewvc/ant/core/trunk/WHATSNEW?view=diff&rev=453401&r1=453400&r2=453401
==============================================================================
--- ant/core/trunk/WHATSNEW (original)
+++ ant/core/trunk/WHATSNEW Thu Oct  5 14:48:49 2006
@@ -40,6 +40,9 @@
 * fix for junit4 issue introducted since beta2.
   Bugzilla report 40682.
 
+* Error in duplicate project name with <import> and <antcall>.
+  Bugzilla report 39920.
+
 Other changes:
 --------------
 

Modified: ant/core/trunk/docs/manual/CoreTasks/import.html
URL: http://svn.apache.org/viewvc/ant/core/trunk/docs/manual/CoreTasks/import.html?view=diff&rev=453401&r1=453400&r2=453401
==============================================================================
--- ant/core/trunk/docs/manual/CoreTasks/import.html (original)
+++ ant/core/trunk/docs/manual/CoreTasks/import.html Thu Oct  5 14:48:49 2006
@@ -79,6 +79,10 @@
 
 <p>Note that &quot;builddocs&quot; is not the filename, but the name attribute
 present in the imported project tag.</p>
+  <p>
+    If import file does not have a name attribute, the ant.file.projectname
+    property will not be set.
+  </p>
 
 <h4>Resolving files against the imported file</h4>
 

Modified: ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java?view=diff&rev=453401&r1=453400&r2=453401
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java Thu Oct  5 14:48:49 2006
@@ -738,7 +738,7 @@
                 }
             }
 
-            if (context.getBuildFile() != null) {
+            if (context.getBuildFile() != null && nameAttributeSet) {
                 project.setUserProperty("ant.file."
                     + context.getCurrentProjectName(),
                     context.getBuildFile().toString());



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org