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/05 13:43:21 UTC

[jira] Created: (HARMONY-2460) [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE

[classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE
-----------------------------------------------------------------------

                 Key: HARMONY-2460
                 URL: http://issues.apache.org/jira/browse/HARMONY-2460
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Denis Kishenko


java.awt.MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE while RI does
not.

========= Test =================
import junit.framework.TestCase;
import java.awt.*;

public class test extends TestCase {      
    public void test1 () { 
      MenuItem obj=new MenuItem("ABC");
      obj.dispatchEvent( new AWTEventImpl(new Button(), 1));          
    }      
}

class AWTEventImpl extends AWTEvent{

    public AWTEventImpl(Event event){
        super(event);
    }

    public AWTEventImpl(Object source, int id){
        super(source, id);
    }
}
Output on Sun 1.5:
==================
.
Time: 0

OK (1 test)

Output on Harmony:
==================
.E
Time: 0.203
There was 1 error:
1) test1(test)java.lang.NullPointerException
        at java.awt.AWTEvent$EventTypeLookup.getEventMask(AWTEvent.java:294)
        at java.awt.MenuItem.processEvent(MenuItem.java:356)
        at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:424)
        at test.test1(test.java:7)
        at java.lang.reflect.VMReflection.invokeMethod(Native Method)

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] Updated: (HARMONY-2460) [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE

Posted by "Andrey Pavlenko (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-2460?page=all ]

Andrey Pavlenko updated HARMONY-2460:
-------------------------------------

    Attachment: AWTEvent.patch
                EventTest.patch

The patch and the regression test are attached.

> [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-2460
>                 URL: http://issues.apache.org/jira/browse/HARMONY-2460
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>         Attachments: AWTEvent.patch, EventTest.patch
>
>
> java.awt.MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE while RI does
> not.
> ========= Test =================
> import junit.framework.TestCase;
> import java.awt.*;
> public class test extends TestCase {      
>     public void test1 () { 
>       MenuItem obj=new MenuItem("ABC");
>       obj.dispatchEvent( new AWTEventImpl(new Button(), 1));          
>     }      
> }
> class AWTEventImpl extends AWTEvent{
>     public AWTEventImpl(Event event){
>         super(event);
>     }
>     public AWTEventImpl(Object source, int id){
>         super(source, id);
>     }
> }
> Output on Sun 1.5:
> ==================
> .
> Time: 0
> OK (1 test)
> Output on Harmony:
> ==================
> .E
> Time: 0.203
> There was 1 error:
> 1) test1(test)java.lang.NullPointerException
>         at java.awt.AWTEvent$EventTypeLookup.getEventMask(AWTEvent.java:294)
>         at java.awt.MenuItem.processEvent(MenuItem.java:356)
>         at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:424)
>         at test.test1(test.java:7)
>         at java.lang.reflect.VMReflection.invokeMethod(Native Method)
> 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-2460) [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE

Posted by "Andrey Pavlenko (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-2460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12464949 ] 

Andrey Pavlenko commented on HARMONY-2460:
------------------------------------------

Mark, the patches have been applied properly. Thanks.

> [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-2460
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2460
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>         Assigned To: Mark Hindess
>         Attachments: AWTEvent.patch, EventTest.patch
>
>
> java.awt.MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE while RI does
> not.
> ========= Test =================
> import junit.framework.TestCase;
> import java.awt.*;
> public class test extends TestCase {      
>     public void test1 () { 
>       MenuItem obj=new MenuItem("ABC");
>       obj.dispatchEvent( new AWTEventImpl(new Button(), 1));          
>     }      
> }
> class AWTEventImpl extends AWTEvent{
>     public AWTEventImpl(Event event){
>         super(event);
>     }
>     public AWTEventImpl(Object source, int id){
>         super(source, id);
>     }
> }
> Output on Sun 1.5:
> ==================
> .
> Time: 0
> OK (1 test)
> Output on Harmony:
> ==================
> .E
> Time: 0.203
> There was 1 error:
> 1) test1(test)java.lang.NullPointerException
>         at java.awt.AWTEvent$EventTypeLookup.getEventMask(AWTEvent.java:294)
>         at java.awt.MenuItem.processEvent(MenuItem.java:356)
>         at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:424)
>         at test.test1(test.java:7)
>         at java.lang.reflect.VMReflection.invokeMethod(Native Method)
> 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] Resolved: (HARMONY-2460) [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE

Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-2460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Hindess resolved HARMONY-2460.
-----------------------------------

    Resolution: Fixed
      Assignee: Mark Hindess

Applied in r495864.  Please confirm that they have been applied as expected.


> [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-2460
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2460
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>         Assigned To: Mark Hindess
>         Attachments: AWTEvent.patch, EventTest.patch
>
>
> java.awt.MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE while RI does
> not.
> ========= Test =================
> import junit.framework.TestCase;
> import java.awt.*;
> public class test extends TestCase {      
>     public void test1 () { 
>       MenuItem obj=new MenuItem("ABC");
>       obj.dispatchEvent( new AWTEventImpl(new Button(), 1));          
>     }      
> }
> class AWTEventImpl extends AWTEvent{
>     public AWTEventImpl(Event event){
>         super(event);
>     }
>     public AWTEventImpl(Object source, int id){
>         super(source, id);
>     }
> }
> Output on Sun 1.5:
> ==================
> .
> Time: 0
> OK (1 test)
> Output on Harmony:
> ==================
> .E
> Time: 0.203
> There was 1 error:
> 1) test1(test)java.lang.NullPointerException
>         at java.awt.AWTEvent$EventTypeLookup.getEventMask(AWTEvent.java:294)
>         at java.awt.MenuItem.processEvent(MenuItem.java:356)
>         at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:424)
>         at test.test1(test.java:7)
>         at java.lang.reflect.VMReflection.invokeMethod(Native Method)
> 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] Closed: (HARMONY-2460) [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE

Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-2460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Hindess closed HARMONY-2460.
---------------------------------


Verified.  Thanks.

> [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-2460
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2460
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>         Assigned To: Mark Hindess
>         Attachments: AWTEvent.patch, EventTest.patch
>
>
> java.awt.MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE while RI does
> not.
> ========= Test =================
> import junit.framework.TestCase;
> import java.awt.*;
> public class test extends TestCase {      
>     public void test1 () { 
>       MenuItem obj=new MenuItem("ABC");
>       obj.dispatchEvent( new AWTEventImpl(new Button(), 1));          
>     }      
> }
> class AWTEventImpl extends AWTEvent{
>     public AWTEventImpl(Event event){
>         super(event);
>     }
>     public AWTEventImpl(Object source, int id){
>         super(source, id);
>     }
> }
> Output on Sun 1.5:
> ==================
> .
> Time: 0
> OK (1 test)
> Output on Harmony:
> ==================
> .E
> Time: 0.203
> There was 1 error:
> 1) test1(test)java.lang.NullPointerException
>         at java.awt.AWTEvent$EventTypeLookup.getEventMask(AWTEvent.java:294)
>         at java.awt.MenuItem.processEvent(MenuItem.java:356)
>         at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:424)
>         at test.test1(test.java:7)
>         at java.lang.reflect.VMReflection.invokeMethod(Native Method)
> 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-2460) [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE

Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-2460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexei Zakharov updated HARMONY-2460:
-------------------------------------

    Patch Info: [Patch Available]

> [classlib][awt] MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-2460
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2460
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>         Attachments: AWTEvent.patch, EventTest.patch
>
>
> java.awt.MenuItem.dispatchEvent(AWTEvent) throws unspecified NPE while RI does
> not.
> ========= Test =================
> import junit.framework.TestCase;
> import java.awt.*;
> public class test extends TestCase {      
>     public void test1 () { 
>       MenuItem obj=new MenuItem("ABC");
>       obj.dispatchEvent( new AWTEventImpl(new Button(), 1));          
>     }      
> }
> class AWTEventImpl extends AWTEvent{
>     public AWTEventImpl(Event event){
>         super(event);
>     }
>     public AWTEventImpl(Object source, int id){
>         super(source, id);
>     }
> }
> Output on Sun 1.5:
> ==================
> .
> Time: 0
> OK (1 test)
> Output on Harmony:
> ==================
> .E
> Time: 0.203
> There was 1 error:
> 1) test1(test)java.lang.NullPointerException
>         at java.awt.AWTEvent$EventTypeLookup.getEventMask(AWTEvent.java:294)
>         at java.awt.MenuItem.processEvent(MenuItem.java:356)
>         at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:424)
>         at test.test1(test.java:7)
>         at java.lang.reflect.VMReflection.invokeMethod(Native Method)
> 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