Summary: | jbig2dec doesn't handle 042_14 | ||
---|---|---|---|
Product: | jbig2dec | Reporter: | Masaki Ushizaka <masaki.ushizaka> |
Component: | Parsing | Assignee: | Henry Stiles <henry.stiles> |
Status: | RESOLVED FIXED | ||
Severity: | major | CC: | robin.watts, shailesh.mistry |
Priority: | P2 | ||
Version: | master | ||
Hardware: | All | ||
OS: | All | ||
Customer: | Word Size: | --- | |
Attachments: | Patch to prevent seg fault |
Description
Masaki Ushizaka
2010-04-21 09:32:00 UTC
Segmentation fault started from following git commit.
> commit df910b6ffff7ae54db6c2d2430709ebb911eda49
> Author: ray <ray@ded80894-8fb9-0310-811b-c03f3676ab4d>
> Date: Tue Aug 16 20:20:08 2005 +0000
>
> Fix for shift right 32 bits of unsigned int being treated as shift right 0.
>
>
> git-svn-id: http://svn.ghostscript.com/jbig2dec/trunk@425 ded80894-8fb9-0310-811b-c03f3676ab4d
For ghostscript subversion repository, this started since r6227.
jbig2dec version 0.9, 0.10, 0.11 all has this problem.
Created attachment 8299 [details]
Patch to prevent seg fault
This patch prevents the seg fault but does not fully implement the missing Ref-Agg Huffman functionality.
I can confirm that this stops both Ghostscript and MuPDF SEGVing on the file in question. A cluster test of Ghostscript shows no ill effects. (In reply to comment #2) > Created an attachment (id=8299) [details] > Patch to prevent seg fault > > This patch prevents the seg fault but does not fully implement the missing > Ref-Agg Huffman functionality. Please commit. The patch was committed as 845ac2669008d3c8daf6461c0fda3b0496d7443e. The test file Jbig2_042_14.pdf has been tried in Adobe PDF reader and with the Luratech code but both fail to render it. It is possible that the test file is actually corrupt. Good enough. |