Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#5667 closed defect (fixed)

Non-fatal libjpeg warnings ignored by JPEG driver

Reported by: Even Rouault Owned by: Even Rouault
Priority: normal Milestone: 1.11.2
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords: jpeg
Cc: warmerdam


Currently the JPEG driver only catches "fatal" libjpeg errors (the ones that use setjmp()/longjmp()). However there are other issues that can occur during JPEG decompression and that libjpeg will categorize only as warnings. Currently we have no GDAL handler for those warnings, so they just end up on the standard error.

We should at least emit a CE_Warning for those. We will introduce a GDAL_ERROR_ON_LIBJPEG_WARNING configuration option, defaulting to FALSE, for backward compatibility purpose, but that can be set to TRUE to trigger a CE_Failure instead for applications that care more about data integrity than resilience to errors.

Change History (3)

comment:1 Changed 7 years ago by Even Rouault

trunk r27742, branches/1.11 r27743 "JPEG: report non-fatal libjpeg errors as CE_Warning (or CE_Failure if GDAL_ERROR_ON_LIBJPEG_WARNING = TRUE) (#5667)"

comment:2 Changed 7 years ago by Even Rouault

Milestone: 1.11.2
Resolution: fixed
Status: newclosed

comment:3 Changed 7 years ago by Even Rouault

trunk r28214 "JPEG: add forgotten part of 1.11 r27743 changeset (trunk only, #5667)"

Note: See TracTickets for help on using tickets.