[gdal-dev] PDF Creation floating point exception for DEFLATE option?

Robert Zermeno refriguy68 at yahoo.com
Mon Nov 26 11:59:23 PST 2012


GDAL Community,
 
My application generates a geospatial PDF file from a pre-loaded image source.  When generating an image, I keep receiving an exception of:
"exception class EInvalidOp with message 'Invalid floating point operation'".  I am using the respoitory from 11-20-2012.  I am using Borland C compiler (now known as Embarcadero Codegear).  
 
For Borland, I found a solution at http://digital.ni.com/public.nsf/allkb/10096EA5DC20FC158625773800628E8A that quited the Invalid floating point operation, but I still get an exception.
 
Finally, I built a simple command line program in MSVC 2005 to step through GDAL source code to find the exception.
 
The exception occurs when using DEFLATE compression option.  The output message I get is located in trees.c (frmts\zlib) from gen_bitlen(s,desc) function lines 532-559.  Zlib is used in pdfcreatecopy.cpp Lines 3496-3501 and 3548.  Line 3548 is where it calls VSIFWriteL().
 
The output string received is:
 
"bit length overflow    
code 0 bits 6->7" 
 
or 
 
"bit length overflow    
code 6 bits 6->7
code 0 bits 6->7"
 
The code and bits are not always the same.  For me, it did not matter which file I used, it always gave me an overflow notice.
Can anyone or has anyone experienced this issue?  The file still generates but my application is halted and a message is presented of the exception.
 
Robert
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20121126/2d6654e1/attachment.html>


More information about the gdal-dev mailing list