kornelski / pngquant

Lossy PNG compressor — pngquant command based on libimagequant library
https://pngquant.org
Other
5.25k stars 486 forks source link

IDAT: incorrect data check (libpng failed) #363

Open peter-gribanov opened 4 years ago

peter-gribanov commented 4 years ago

Found a problem with file compression.

# pngquant pngquant_fail.png
  error: IDAT: incorrect data check (libpng failed)
  error: cannot decode image pngquant_fail.png

The file is perfectly normal. Opens correctly in many programs. There is no apparent reason for the failure.

The file was created in Adobe Photoshop. We managed to solve the problem by re-saving the file in Adobe Photoshop. But still i would like to know what was the problem with this file?

# pngquant -v
No input files specified.
pngquant, 2.12.5 (July 2019), by Kornel Lesinski, Greg Roelofs.
   Compiled with OpenMP (multicore support).
   Color profiles are supported via Little CMS. Using libpng 1.6.34.
# sudo yum list installed | grep png
libpng.x86_64                        2:1.6.34-5.el8                                   @anaconda
libpng-devel.x86_64                  2:1.6.34-5.el8                                   @BaseOS
libpng12.x86_64                      1.2.57-5.el8                                     @AppStream
pngquant.x86_64                      2.12.5-1.el8                                     @epel
Bad image pngquant incorrect data check