harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Denis Kishenko (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-1471) [classlib][awt] TexturePaint expected NPE if one of input parameters is null
Date Tue, 19 Sep 2006 07:53:23 GMT
    [ http://issues.apache.org/jira/browse/HARMONY-1471?page=comments#action_12435719 ] 
            
Denis Kishenko commented on HARMONY-1471:
-----------------------------------------

Sorry, Harmony output is
========== Harmony output ======== 
1 
2 
without any exception. It was my local problem.

> [classlib][awt] TexturePaint expected NPE if one of input parameters is null
> ----------------------------------------------------------------------------
>
>                 Key: HARMONY-1471
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1471
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Denis Kishenko
>
> Harmony implementation of TexturePaint  doesn't check null value of input parameters
while RI does and throws NPE
> =========== Spec =================
> Nothing about exceptions
> ============== Test.java =============
> import java.awt.*;
> import java.awt.image.BufferedImage;
> public class Test {
>     static public void main(String[] args) {
>         try {
>             System.err.println("1");
>             new TexturePaint(null, new Rectangle());            
>         } catch (Exception e) {
>             e.printStackTrace();
>         }
>         try {
>             System.err.println("2");
>             new TexturePaint(new BufferedImage(1, 1, 1), null);            
>         } catch (Exception e) {
>             e.printStackTrace();
>         }
>     }
> }
> ============= RI output ============
> 1
> java.lang.NullPointerException
>     at java.awt.TexturePaint.<init>(TexturePaint.java:54)
>     at Test.main(Test.java:9)
> 2
> java.lang.NullPointerException
>     at java.awt.TexturePaint.<init>(TexturePaint.java:52)
>     at Test.main(Test.java:15)
> ========== Harmony output ========
> 1
> 2
> java.lang.UnsatisfiedLinkError: 
>     at org.apache.harmony.awt.gl.Surface.<clinit>(Surface.java:84)
>     at java.awt.image.BufferedImage.createImageSurface(BufferedImage.java:659)
>     at java.awt.image.BufferedImage.<init>(BufferedImage.java:352)
>     at bug9768.main(bug9768.java:15)

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

        

Mime
View raw message