ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 24024] New: - Definer could load all antlibs matching a resource path
Date Thu, 23 Oct 2003 00:29:21 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24024>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24024

Definer could load all antlibs matching a resource path

           Summary: Definer could load all antlibs matching a resource path
           Product: Ant
           Version: 1.6Beta
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Minor
          Priority: Other
         Component: Core tasks
        AssignedTo: dev@ant.apache.org
        ReportedBy: jglick@netbeans.org


If you call

<taskdef classpath="..." resource="foo/antlib.xml" uri="antlib:foo"/>

or just start using

<sometask xmlns="antlib:foo"/>

with foo/antlib.xml in the classpath, currently it seems that Definer will only
look for one instance of the resource "foo/antlib.xml". If there are multiple
JARs in the classpath containing "foo/antlib.xml", only one of them (acc. to
classpath order) will actually be loaded.

IMHO probably all of them should be loaded. But I am not sure if the current
behavior is intentional or simply an oversight. If an oversight, I would be
willing to supply a patch. Should be pretty trivial: Definer.resourceToURL
should call ClassLoader.getAllResources() and return Enumeration<URL> and
Definer.execute() should simply iterate over each URL and otherwise behave as now.

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


Mime
View raw message