Re: Fix for 686779, /ioerror in --token--, new approach
"Igor V. Melichev" <[email protected]>
| Newsgroups | gmane.comp.printing.ghostscript.patches |
|---|---|
| Message-ID | <[email protected]> |
> From: "Alex Cherepanov" <[email protected]> > To: "gs-code-review" <[email protected]> > Sent: Friday, November 14, 2003 8:02 PM > Subject: [gs-code-review] Fix for 686779, /ioerror in --token--, new approach > JAWS PDF generator encodes empty stream as jaws_empty[]. The stream > declares that the data block length is zero but zlib routines regard a > zero length data block to be a error. Check for this case and return > EOF without calling zlib. > Fix bug 686779 from the customer 131 Looks good. > If we choose to apply /SubFileDecode filter to all streams we can > compare the length for equality and reduce the number of calls to > memcmp(). I don't think that memcmp in this context consumes a significant time. You also may optomize with "unsigned short int jaws_empty[5]" and 5 integer comparizons. Or with 2 unsigned long and 1 unsugned short. > I think that a half of the bug bounty should go to > Shailesh L Mistry <[email protected]> > who have analyzed the problem and whose proposal was eventually > implemented. This to be addressed to Miles. Igor.