You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Mark Hindess (JIRA)" <ji...@apache.org> on 2007/01/13 14:30:27 UTC
[jira] Commented: (HARMONY-2019) [classlib][awt]
Container.remove(null) expected NPE
[ https://issues.apache.org/jira/browse/HARMONY-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12464459 ]
Mark Hindess commented on HARMONY-2019:
---------------------------------------
I tried these patches and I get:
testRemoveComponent Failure NPE was not thrown
junit.framework.AssertionFailedError: NPE wa
not thrown at
java.awt.ContainerRTest.testRemoveComponent
(ContainerRTest.java:37) at
java.lang.reflect.AccessibleObject.invokeV
(AccessibleObject.java:25)
> [classlib][awt] Container.remove(null) expected NPE
> ---------------------------------------------------
>
> Key: HARMONY-2019
> URL: https://issues.apache.org/jira/browse/HARMONY-2019
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Denis Kishenko
> Attachments: Container.patch, ContainerRTest.patch
>
>
> Harmony implementation of Container.remove(Component ) doesn't throw NPE while RI does. Spec silent about any exceptions.
> ========== Test ============
> import java.awt.*;
> public class Test {
> static public void main(String[] args) {
> Container cmp = new Container();
> cmp.remove((Button )null);
> System.out.println("PASSED");
> }
> }
> ======== RI ===========
> java.lang.NullPointerException
> at java.awt.Container.remove(Container.java:1165)
> at Test.main(Test.java:9)
> ===== Harmony ========
> PASSED
--
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