Bug 690583

Summary: ghostscript crashes when interpreting PDF file
Product: Ghostscript Reporter: Hans Randgaard <hans.b.randgaard>
Component: PDF InterpreterAssignee: Alex Cherepanov <alex>
Status: NOTIFIED WORKSFORME    
Severity: critical    
Priority: P4    
Version: 8.15   
Hardware: PC   
OS: Linux   
Customer: Word Size: ---
Attachments: Faktura557655.pdf

Description Hans Randgaard 2009-06-29 04:45:24 UTC
When trying to convert a PDF file to TIFF using the command:
 
/usr/bin/convert -density 300x300 -monochrome -sharpen 1,1 -enhance
Faktura557655.pdf Faktura557655.tif
 
ghostscript crashes with the following error:
 
ERROR: /rangecheck in --cvrs--
Operand stack:
   --dict:5/5(L)--   1   C2_1   1   --dict:6/6(L)--   --dict:6/6(L)--  
LEBBII+Wingdings-Regular   --dict:10/12(ro)(G)--   --nostringval--  
--dict:7/7(L)--   --dict:7/7(L)--   77435   --dict:7/7(L)--   --nostringval--  
FontMatrix   --nostringval--   FontBBox   --nostringval--   FontName  
-2147483646   16   (\000\000\000\000\000\000\000\000)
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--  
--nostringval--   2   %stopped_push   --nostringval--   --nostringval--  
--nostringval--   false   1   %stopped_push   1   3   %oparray_pop   1   3  
%oparray_pop   1   3   %oparray_pop   --nostringval--   --nostringval--   2   1
  1   --nostringval--   %for_pos_int_continue   --nostringval--  
--nostringval--   --nostringval--   --nostringval--   %array_continue  
--nostringval--   false   1   %stopped_push   --nostringval--   %loop_continue 
 --nostringval--   2129   --nostringval--   3   11   %oparray_pop  
--nostringval--   false   1   %stopped_push   3   11   %oparray_pop  
--nostringval--   (gstatetype)   --dict:0/0(L)--   --nostringval--   false   1 
 %stopped_push   --nostringval--   %loop_continue   --nostringval--  
--nostringval--   --nostringval--   --nostringval--   --nostringval--  
%array_continue   --nostringval--   --nostringval--   --nostringval--  
--nostringval--   --nostringval--   --nostringval--
Dictionary stack:
   --dict:1127/1686(ro)(G)--   --dict:0/20(G)--   --dict:107/200(L)--  
--dict:107/200(L)--   --dict:104/127(ro)(G)--   --dict:241/347(ro)(G)--  
--dict:20/24(L)--   --dict:4/6(L)--   --dict:20/20(L)--   --dict:1/1(ro)(G)--  
--dict:10/14(L)--   --dict:7/8(L)--   --dict:33/50(ro)(G)--   --dict:24/40(L)--
Current allocation mode is local
ESP Ghostscript 815.02: Unrecoverable error, exit code 1
convert: Postscript delegate failed `Faktura557655.pdf'.
convert: missing an image filename `Faktura557655.tif'.
Comment 1 Hans Randgaard 2009-06-29 04:53:40 UTC
Created attachment 5170 [details]
Faktura557655.pdf

To make it possible for you to reproduce the crash
Comment 2 Marcos H. Woehrmann 2009-06-29 06:52:17 UTC
The current version of Ghostscript, 8.64, processes the attached file without problem.  I don't know what 
release ESP Ghostscript 815.02 is equivalent to, but I suspect it's quite old.
Comment 3 Hans Randgaard 2009-06-29 07:00:44 UTC
We run RedHat 5.3
I have reported it to RedHat as well.
Thanks for feedback !

Cheers, Hans.
Comment 4 Alex Cherepanov 2009-06-29 09:21:00 UTC
This issue has been fixed -- twice.

Many PostScript programs assume that integers are 32-bit long.
First, PS code was modified in a few places prone to integer overflow.
Current development version always use 32-bit integers, and out-of-range
integers cannot appear at all.

ESP Ghostscript 815.02 is an unofficial fork of our v. 8.15.