harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vladimir Ivanov (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-1568) [classlib][beans] XMLDecoder(3 params).getExceptionListener() returns object on RI and 'null' on Harmony
Date Thu, 09 Aug 2007 06:01:42 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-1568?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12518619
] 

Vladimir Ivanov commented on HARMONY-1568:
------------------------------------------

I ran this test on jdk build. This issue was fixed. Thanks. 
But I observed unexpected exception. Could you reproduce it?

Execution log:
tmp17>trunk\target\hdk\jdk\bin\java.exe -showversion test
Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software Foundatio
n or its licensors, as applicable.
java version "1.5.0"
pre-alpha : not complete or compatible
svn = r563001, (Aug  6 2007), Windows/ia32/msvc 1310, release build
http://harmony.apache.org
org.xml.sax.SAXParseException: Content is not allowed in prolog.
        at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Un
known Source)
        at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source)

        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLScanner.reportFatalError(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentScannerImpl$PrologDispatcher.dispat
ch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un
known Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Sour
ce)
        at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source)
        at javax.xml.parsers.SAXParser.parse(Unknown Source)
        at java.beans.XMLDecoder.<init>(XMLDecoder.java:472)
        at test.main(test.java:6)
Continue...
org.xml.sax.SAXParseException: Content is not allowed in prolog.
        at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Sour
ce)
        at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source)
        at javax.xml.parsers.SAXParser.parse(Unknown Source)
        at java.beans.XMLDecoder.<init>(XMLDecoder.java:472)
        at test.main(test.java:6)
Continue...
res = java.beans.XMLDecoder$DefaultExceptionListener@81df0fb


> [classlib][beans] XMLDecoder(3 params).getExceptionListener() returns object on RI and
'null' on Harmony
> --------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-1568
>                 URL: https://issues.apache.org/jira/browse/HARMONY-1568
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Vladimir Ivanov
>            Assignee: Tim Ellison
>         Attachments: beans.patch
>
>
> The spec says for the constructor XMLDecoder(InputStream in, Object owner, ExceptionListener
exceptionListener): 
>  "exceptionListener - the exception handler for the stream; if null the default exception
listener will be used"
> The RI use default listener while harmony 'null'.
> ============== test.java ====================
> import java.beans.*;
> import java.io.ByteArrayInputStream;
> public class test {     
>    public static void main(String[] args) {  
>        System.out.println("res = " + new XMLDecoder(new ByteArrayInputStream(new byte[]
{1, 2}), new Double(1), null).getExceptionListener());
>     }    
> }
> =========================================
> Output:
> C:\tmp\tmp17>C:\jrockit-jdk1.5.0-windows-ia32\bin\java.exe -cp . -showversion test
> java version "1.5.0"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
> BEA WebLogic JRockit(R) (build dra-38972-20041208-2001-win-ia32, R25.0.0-75, GC: System
optimized over throughput (initial strategy singleparpar))
> res = java.beans.Statement$1@1b3534
> C:\tmp\tmp17>C:\harmony\classlib1.5\deploy\jdk\jre\bin\java.exe -cp . test
> res = null

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message