Comment 4 for bug 153765

Revision history for this message
Ralph Giles (giles-ghostscript) wrote :

Thanks for the prompt response!

There are two main issues: One is a patch for handling broken streams produced by certain popular authoring software. Upstream rejected the patch because it increases memory footprint (a "you can free this" tag is incorrect in these files). A combination of not-my-problem and the usual tension between a reference implementation and liberal acceptance for applications. The jpeg2k implementation in libpoppler works around such files in the same way.

Analysis and patch here: http://bugs.ghostscript.com/show_bug.cgi?id=687416

The second is a patch to add support for returning raw palette data, which is required by the PDF spec. I haven't tried getting this one upstream.

Since then our fork has diverged a bit more (error reporting through a callback instead of printf() and assert() and some optimizations, both of which are most important on Windows) but the API difference can be ifdef'd around. So lInking with the system libjasper could be done at the expense of handling these files. Or you could apply our patches to your libjasper. The two specific ones mentioned above are ABI compatible.

I hope to try again for upstream inclusion when I get a chance to merge our changes into the 1.900.1 release.