You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Sergey Krivenko (JIRA)" <ji...@apache.org> on 2006/12/25 17:20:23 UTC

[jira] Updated: (HARMONY-2765) [classlib][swing] javax.swing.plaf.basic.BasicInternalFrameUI. createNorthPane(null) does not throw unspecified NPE

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

Sergey Krivenko updated HARMONY-2765:
-------------------------------------

    Attachment: Harmony-2765-BasicInternalFrameUI.patch

the attached file is a patch that fixes the bug

> [classlib][swing] javax.swing.plaf.basic.BasicInternalFrameUI. createNorthPane(null) does not throw unspecified NPE
> -------------------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-2765
>                 URL: http://issues.apache.org/jira/browse/HARMONY-2765
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>         Attachments: Harmony-2765-BasicInternalFrameUI.patch
>
>
> There is no mention of any exception in the specification.
> RI throws unspecified NPE for createNorthPane(null) while Harmony does not.
> Note, both RI and Harmony don't throw NPE for
> createSouthPane(null)
> createEastPane(null)
> createWestPane(null).
> import javax.swing.plaf.basic.*;
> import javax.swing.*;
> public class test {
>     public static void main(String[] args) {               
>         try {   
>             testBasicInternalFrameUI fr = new testBasicInternalFrameUI(null);
>             fr.createNorthPane(null);   
>         } catch (Exception e) { 
>             e.printStackTrace();
>         } 
>     }                                                                        
> }
> class testBasicInternalFrameUI  extends BasicInternalFrameUI {
>      testBasicInternalFrameUI (JInternalFrame c){
>          super(c);  
>      }
>      public JComponent createNorthPane(JInternalFrame  c)  {
>          return super.createNorthPane(c);       
>      }      
> }
> Output on RI:
> java.lang.NullPointerException
>         at
> javax.swing.plaf.basic.BasicInternalFrameTitlePane.installListeners(BasicInternalFrameTitlePane.java:139)
>         at
> javax.swing.plaf.basic.BasicInternalFrameTitlePane.installTitlePane(BasicInternalFrameTitlePane.java:98)
>         at
> javax.swing.plaf.basic.BasicInternalFrameTitlePane.<init>(BasicInternalFrameTitlePane.java:93)
>         at
> javax.swing.plaf.basic.BasicInternalFrameUI.createNorthPane(BasicInternalFrameUI.java:332)
>         at testBasicInternalFrameUI.createNorthPane(test.java:31)
>         at test.main(test.java:8)
> Output on Harmony +j9:
> (no output)

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