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/12/18 12:53:23 UTC
[jira] Created: (HARMONY-2768) [classlib][swing]
javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
[classlib][swing] javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
--------------------------------------------------------------------------------------
Key: HARMONY-2768
URL: http://issues.apache.org/jira/browse/HARMONY-2768
Project: Harmony
Issue Type: Bug
Components: Classlib
Reporter: Denis Kishenko
RI throws NPE for DefaultListCellRenderer.repaint(null) while Harmony does not.
There is no mention of this condition in the specification.
It is compatibility issue.
import junit.framework.TestCase;
import javax.swing.*;
public class test extends TestCase {
public void testcase1() {
DefaultListCellRenderer pi = new javax.swing.DefaultListCellRenderer();
pi.repaint(null);
}
}
Output on RI:
.
Time: 0,156
OK (1 test)
Output on Harmony:
.E
Time: 0.344
There was 1 error:
1) testcase1(test)java.lang.NullPointerException
at javax.swing.JComponent.repaint(JComponent.java:914)
at test.testcase1(test.java:8)
at java.lang.reflect.VMReflection.invokeMethod()
FAILURES!!!
Tests run: 1, Failures: 0, Errors: 1
--
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
[jira] Commented: (HARMONY-2768) [classlib][swing]
javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
Posted by "Kalpak Gadre (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465416 ]
Kalpak Gadre commented on HARMONY-2768:
---------------------------------------
Proposed patch.
> [classlib][swing] javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
> --------------------------------------------------------------------------------------
>
> Key: HARMONY-2768
> URL: https://issues.apache.org/jira/browse/HARMONY-2768
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Denis Kishenko
> Attachments: HARMONY-2768.patch.txt
>
>
> RI throws NPE for DefaultListCellRenderer.repaint(null) while Harmony does not.
> There is no mention of this condition in the specification.
> It is compatibility issue.
> import junit.framework.TestCase;
> import javax.swing.*;
> public class test extends TestCase {
> public void testcase1() {
> DefaultListCellRenderer pi = new javax.swing.DefaultListCellRenderer();
> pi.repaint(null);
> }
> }
> Output on RI:
> .
> Time: 0,156
> OK (1 test)
> Output on Harmony:
> .E
> Time: 0.344
> There was 1 error:
> 1) testcase1(test)java.lang.NullPointerException
> at javax.swing.JComponent.repaint(JComponent.java:914)
> at test.testcase1(test.java:8)
> at java.lang.reflect.VMReflection.invokeMethod()
> FAILURES!!!
> Tests run: 1, Failures: 0, Errors: 1
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2768) [classlib][swing]
javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
Posted by "Dmitry Irlyanov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465501 ]
Dmitry Irlyanov commented on HARMONY-2768:
------------------------------------------
Or close this issue as non-bug diff
> [classlib][swing] javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
> --------------------------------------------------------------------------------------
>
> Key: HARMONY-2768
> URL: https://issues.apache.org/jira/browse/HARMONY-2768
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Denis Kishenko
> Attachments: HARMONY-2768.patch.txt
>
>
> RI throws NPE for DefaultListCellRenderer.repaint(null) while Harmony does not.
> There is no mention of this condition in the specification.
> It is compatibility issue.
> import junit.framework.TestCase;
> import javax.swing.*;
> public class test extends TestCase {
> public void testcase1() {
> DefaultListCellRenderer pi = new javax.swing.DefaultListCellRenderer();
> pi.repaint(null);
> }
> }
> Output on RI:
> .
> Time: 0,156
> OK (1 test)
> Output on Harmony:
> .E
> Time: 0.344
> There was 1 error:
> 1) testcase1(test)java.lang.NullPointerException
> at javax.swing.JComponent.repaint(JComponent.java:914)
> at test.testcase1(test.java:8)
> at java.lang.reflect.VMReflection.invokeMethod()
> FAILURES!!!
> Tests run: 1, Failures: 0, Errors: 1
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2768) [classlib][swing]
javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
Posted by "Dmitry Irlyanov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465499 ]
Dmitry Irlyanov commented on HARMONY-2768:
------------------------------------------
Kalpak,
It's the compartibility issue therefore the proposed fix should fully corresponds the RI.
Your patch changes JComonent class, but JComonent in RI do throw NullPointerException
Try this:
public void testcase1() {
JLabel pi = new JLabel();
pi.repaint(null);
}
------Output on RI------
.E
Time: 0.14
There was 1 error:
1) testcase1(H2768)java.lang.NullPointerException
at javax.swing.JComponent.repaint(JComponent.java:4532)
at H2768.testcase1 (H2768.java:11)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:25)
at H2768.main(H2768.java:15)
FAILURES!!!
Tests run: 1, Failures: 0, Errors: 1
The correct patch for this issue is repaint method implementation for DefaultListCellRenderer
> [classlib][swing] javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
> --------------------------------------------------------------------------------------
>
> Key: HARMONY-2768
> URL: https://issues.apache.org/jira/browse/HARMONY-2768
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Denis Kishenko
> Attachments: HARMONY-2768.patch.txt
>
>
> RI throws NPE for DefaultListCellRenderer.repaint(null) while Harmony does not.
> There is no mention of this condition in the specification.
> It is compatibility issue.
> import junit.framework.TestCase;
> import javax.swing.*;
> public class test extends TestCase {
> public void testcase1() {
> DefaultListCellRenderer pi = new javax.swing.DefaultListCellRenderer();
> pi.repaint(null);
> }
> }
> Output on RI:
> .
> Time: 0,156
> OK (1 test)
> Output on Harmony:
> .E
> Time: 0.344
> There was 1 error:
> 1) testcase1(test)java.lang.NullPointerException
> at javax.swing.JComponent.repaint(JComponent.java:914)
> at test.testcase1(test.java:8)
> at java.lang.reflect.VMReflection.invokeMethod()
> FAILURES!!!
> Tests run: 1, Failures: 0, Errors: 1
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (HARMONY-2768) [classlib][swing]
javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
Posted by "Kalpak Gadre (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kalpak Gadre updated HARMONY-2768:
----------------------------------
Attachment: HARMONY-2768.patch.txt
> [classlib][swing] javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
> --------------------------------------------------------------------------------------
>
> Key: HARMONY-2768
> URL: https://issues.apache.org/jira/browse/HARMONY-2768
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Denis Kishenko
> Attachments: HARMONY-2768.patch.txt
>
>
> RI throws NPE for DefaultListCellRenderer.repaint(null) while Harmony does not.
> There is no mention of this condition in the specification.
> It is compatibility issue.
> import junit.framework.TestCase;
> import javax.swing.*;
> public class test extends TestCase {
> public void testcase1() {
> DefaultListCellRenderer pi = new javax.swing.DefaultListCellRenderer();
> pi.repaint(null);
> }
> }
> Output on RI:
> .
> Time: 0,156
> OK (1 test)
> Output on Harmony:
> .E
> Time: 0.344
> There was 1 error:
> 1) testcase1(test)java.lang.NullPointerException
> at javax.swing.JComponent.repaint(JComponent.java:914)
> at test.testcase1(test.java:8)
> at java.lang.reflect.VMReflection.invokeMethod()
> FAILURES!!!
> Tests run: 1, Failures: 0, Errors: 1
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (HARMONY-2768) [classlib][swing]
javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Alexei Zakharov updated HARMONY-2768:
-------------------------------------
Priority: Minor (was: Major)
> [classlib][swing] javax.swing.DefaultListCellRenderer.repaint(null) does not throw NPE
> --------------------------------------------------------------------------------------
>
> Key: HARMONY-2768
> URL: https://issues.apache.org/jira/browse/HARMONY-2768
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Denis Kishenko
> Priority: Minor
> Attachments: HARMONY-2768.patch.txt
>
>
> RI throws NPE for DefaultListCellRenderer.repaint(null) while Harmony does not.
> There is no mention of this condition in the specification.
> It is compatibility issue.
> import junit.framework.TestCase;
> import javax.swing.*;
> public class test extends TestCase {
> public void testcase1() {
> DefaultListCellRenderer pi = new javax.swing.DefaultListCellRenderer();
> pi.repaint(null);
> }
> }
> Output on RI:
> .
> Time: 0,156
> OK (1 test)
> Output on Harmony:
> .E
> Time: 0.344
> There was 1 error:
> 1) testcase1(test)java.lang.NullPointerException
> at javax.swing.JComponent.repaint(JComponent.java:914)
> at test.testcase1(test.java:8)
> at java.lang.reflect.VMReflection.invokeMethod()
> FAILURES!!!
> Tests run: 1, Failures: 0, Errors: 1
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.