You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Denis Kishenko (JIRA)" <ji...@apache.org> on 2006/10/03 11:56:21 UTC

[jira] Updated: (HARMONY-1667) [classlib][awt] RI BorderLayout.addLayoutComponent(Component, null) throws NPE while Harmony doesn't

     [ http://issues.apache.org/jira/browse/HARMONY-1667?page=all ]

Denis Kishenko updated HARMONY-1667:
------------------------------------

    Attachment: HARMONY-1667-BorderLayoutTest.patch

test

Actually problem was with the first Component parameter only. 

> [classlib][awt] RI BorderLayout.addLayoutComponent(Component, null) throws NPE while Harmony doesn't
> ----------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-1667
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1667
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>            Priority: Minor
>         Attachments: HARMONY-1667-BorderLayout.patch, HARMONY-1667-BorderLayoutTest.patch
>
>
> Harmony BorderLayout .addLayoutComponent(Component, Object) doesn't throw NPE while RI does if constraints parameter is null. Spec doesn't say anything about NPE.
> ============== Test ==================
> import java.awt.BorderLayout;
> import java.awt.Component;
> public class Test {
>     public static void main(String[] argv) {
>         BorderLayout layout = new BorderLayout();
>         layout.addLayoutComponent((Component) null,(Object)  null);
>    }
> }
> =========== RI output ==============
> java.lang.NullPointerException
>     at java.awt.BorderLayout.addLayoutComponent(BorderLayout.java:405)
>     at Test.main(Test.java:7)
> ======= Harmony output ============
> nothing

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