Lymphatus / caesium-image-compressor

Caesium is an image compression software that helps you store, send and share digital pictures, supporting JPG, PNG, WebP and TIFF formats. You can quickly reduce the file size (and resolution, if you want) by preserving the overall quality of the image.
https://saerasoft.com/caesium
GNU General Public License v3.0
3.47k stars 209 forks source link

Crashes when compressing corrupted files #200

Closed KillianVbrg closed 1 year ago

KillianVbrg commented 1 year ago

Hi and thank you for your amazing tool! 😍 I am working with huge datasets of photos... And the thing is that some are corrupted (like 1% max). I can't check them all individually of course, and when I use Caesium and it is trying to compress a corrupted file, it crashes 🫤 Is there a way to avoid this? Can be a solution out of Caesium too that I don't know to check the integrity of all the files and delete the corrupted ones? 🥲

Thanks again! 👋

Lymphatus commented 1 year ago

Hello! Can you share a couple of corrupted pictures so I can run some tests on them? Thanks!

KillianVbrg commented 1 year ago

Ok here is a picture, I'll send others to you when I run into them. https://drive.google.com/file/d/1_hyAekPz8H5ux4dT9gXozQUiJ9P57YbX/view?usp=sharing

You're welcome :)

KillianVbrg commented 1 year ago

Hello! The app crashed when it ran into those files: https://drive.google.com/drive/folders/1CjEtClCX7CzCNDxJI25CStO_pkIplHa0?usp=sharing

Lymphatus commented 1 year ago

It's a problem with libcaesium not able to handle the corrupted files correctly. I need to fix it there and then ship a bugfix version of the app.

Lymphatus commented 1 year ago

Fixed in v2.4.1