harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexey Varlamov (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-1651) [drlvm][kernel] Some issues in j.l.Package implementation
Date Wed, 04 Oct 2006 11:17:26 GMT
    [ http://issues.apache.org/jira/browse/HARMONY-1651?page=comments#action_12439799 ] 
Alexey Varlamov commented on HARMONY-1651:

Seems like RI behaves slightly differently from spec - then I agree, we should follow RI in
this case.
However I dislike the following construct:

} catch (NullPointerException e) { 
            if(specVersion == null) { 
                throw new NumberFormatException("Empty version string"); 
            throw e; 

Let's simply move the if to beginning of the method and do not catch NPE at all.

BTW, I found related bug in Sun's database, which we should also fix: [1]. It would be nice
to have 1 patch for all, could you please look at this?
[1] http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4227825

> [drlvm][kernel] Some issues in j.l.Package implementation
> ---------------------------------------------------------
>                 Key: HARMONY-1651
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1651
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>            Reporter: Serguei Zapreyev
>         Attachments: H1651.jlP_impl.patch, Test1.java, Test2.java, Test3.java
> Some defects in Package impl: 
> - Package.isCompatibleWith("") throws NPE instead of NumberFormatException (Teast1).

>   Throwing the NumberFormatException as demanded resolves the issue. 
> - java.lang.Package.isSealed((java.net.URL)null) should throw NPE (Teast2). 
>   Throwing the NulPointerException as demanded resolves the issue. 
> - pakage info inaccessibility (DRLVM does not provide access to information describing
a package.)   
>   (Teast3). 
>   Changing the dot-separated Manifest entry name form to slash-separated one resolves
the issue.
> I'm going to attach the corresponding patch to fix the issues and the corresponding tests.

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message