Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#30 piccolo failed on gzip files

v1.04
open
nobody
None
5
2008-09-23
2008-09-23
Anonymous
No

I used piccolo with this piece of code:

is= new FileInputStream(d);
if (d.getName().endsWith(".gz"))
{
is= new GZIPInputStream(is);
}
saxparser.parse(is, myhandler);

when files are not gzipped, it works very well (and fast).
when gziped, it always failed with a
1:-1 XML declaration is not well-formed
org.xml.sax.SAXParseException: XML declaration is not well-formed
at com.bluecast.xml.Piccolo.reportFatalError(Piccolo.java:1038)
at com.bluecast.xml.Piccolo.parse(Piccolo.java:723)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:395)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:198)
at ...

using apache.xerces it work well on the same gziped files.

Discussion

  • sample gziped file

     
    Attachments