Bug 690597

Summary: Interpretation of PDF file fails with typecheck after the 41. page
Product: Ghostscript Reporter: artifex
Component: PDF InterpreterAssignee: Alex Cherepanov <alex>
Status: NOTIFIED FIXED    
Severity: normal    
Priority: P2    
Version: 8.64   
Hardware: PC   
OS: Windows XP   
Customer: 870 Word Size: ---

Description artifex 2009-07-03 07:12:24 UTC
When the attached file Harzt-ghost.pdf is interpreted with the Ghostscript ( for
example:  gs -sDEVICE=tiffg4 -dNOPAUSE -o out.tif Harzt-ghost.pdf ) , the
processing fails after the 41. page with a typecheck.
Comment 1 artifex 2009-07-03 07:13:44 UTC
Created attachment 5181 [details]
Harzt-ghost.pdf
Comment 2 Alex Cherepanov 2009-07-03 10:41:32 UTC
The file has the following invalid reference:

  395 0 obj <</Type/ExtGState /SMask 0 0 R>> endobj

Probably, Ghostscript should check for "0 0 R" and consider the attribute
undefined. This check won't slow PDF interpreter too much if "knownoget"
procedure is ported to C.
Comment 3 Alex Cherepanov 2009-07-04 15:49:19 UTC
Add a check for a null value of SMask attribute in ExtGState. This also works
for invalid SMask reference, which is already converted to null.

The following patch has been committed as a rev. 9839.
http://ghostscript.com/pipermail/gs-cvs/2009-July/009518.html
Regression testing shows no differences.
Comment 4 Marcos H. Woehrmann 2011-09-18 21:47:27 UTC
Changing customer bugs that have been resolved more than a year ago to closed.