corona icon indicating copy to clipboard operation
corona copied to clipboard

Fix: Loading an invalid image causes a crash

Open aoyako opened this issue 1 year ago • 1 comments

Platform: Linux Fix the issue when Solar crashes with a segmentation fault on loading an invalid image file (.png, .jpg, .bmp).

Steps to reproduce:

  1. Create an empty file with the extension .png (empty.png)
  2. Put the following line in the new project's main.lua local background = display.newImageRect("empty.png", 600, 600)

Expected behavior:

Runtime Error is reported.

Actual behavior:

Solar crashed, leaving a log

libpng error: Read Error
Segmentation fault

aoyako avatar Feb 21 '24 08:02 aoyako

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Feb 21 '24 08:02 CLAassistant