ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maarten Coene (JIRA)" <j...@apache.org>
Subject [jira] Assigned: (IVY-776) NPE when specifying both resolveId and inline in an Ivy:Resolve
Date Tue, 18 Mar 2008 22:50:24 GMT

     [ https://issues.apache.org/jira/browse/IVY-776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Maarten Coene reassigned IVY-776:
---------------------------------

    Assignee: Maarten Coene

> NPE when specifying both resolveId and inline in an Ivy:Resolve 
> ----------------------------------------------------------------
>
>                 Key: IVY-776
>                 URL: https://issues.apache.org/jira/browse/IVY-776
>             Project: Ivy
>          Issue Type: Bug
>          Components: Ant
>    Affects Versions: 2.0.0-beta-1, 2.0.0-beta-2
>         Environment: Windows XP, Ivy 2 beta 1 and beta 2
>            Reporter: Nascif Abousalh-Neto
>            Assignee: Maarten Coene
>             Fix For: 2.0
>
>
> If I specify both inline mode (in which case file has to be null) and resolveId, IvyResolve
will die with a NPE when trying to get the value to set on "ivy.resolved.file." + resolveId.
It dies on the call to file.getAbsolutePath(). Note how file is checked for null outside of
the resolveId code branch, but not inside.
> Also, why are the basic properties (like "ivy.resolved.file") always set even if resolveId
is specified? I would expect that one or the other set of properties would be set, but not
both. 
> IvyResolve.java, line 269 (on beta-2)
>                 if (file != null) {
>                     getProject().setProperty("ivy.resolved.file", file.getAbsolutePath());
>                     settings.setVariable("ivy.resolved.file", file.getAbsolutePath());
>                 }
>                 if (resolveId != null) {
>                     ...
>                     getProject().setProperty("ivy.resolved.file." + resolveId,
>                         file.getAbsolutePath());
>                     settings
>                             .setVariable("ivy.resolved.file." + resolveId, file.getAbsolutePath());
>                 }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message