ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xavier Hanin (JIRA)" <j...@apache.org>
Subject [jira] Commented: (IVY-805) onMissingDescriptor doesn't work due to == comparison
Date Sun, 20 Apr 2008 10:28:21 GMT

    [ https://issues.apache.org/jira/browse/IVY-805?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12590756#action_12590756
] 

Xavier Hanin commented on IVY-805:
----------------------------------

Damned, I'm surprised I'm still able to do such an obvious mistake :-( Thanks for reporting

> onMissingDescriptor doesn't work due to == comparison
> -----------------------------------------------------
>
>                 Key: IVY-805
>                 URL: https://issues.apache.org/jira/browse/IVY-805
>             Project: Ivy
>          Issue Type: Bug
>          Components: Ant
>    Affects Versions: 2.0-RC1
>            Reporter: Ben Hale
>         Attachments: onMissingDescriptor.patch
>
>
> In the IvyBuildList file, you compare the value passed for onMissingDescriptor to a set
of constants using the '==' operator.  In Java, this will always return false unless you have
the exact same instance (which is unlikely in this case :))  The code should use the .equals()
method which will return true when strings are identical, even when they are not the same
instance.

-- 
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