display png error when we cannot read a png

This commit is contained in:
Dane Springmeyer 2013-07-14 16:32:32 -04:00
parent 0b58eea131
commit 09aad15eb2

View file

@ -98,7 +98,7 @@ const bool registered2 = register_image_reader("png", create_png_reader2);
void user_error_fn(png_structp png_ptr, png_const_charp error_msg)
{
throw image_reader_exception("failed to read invalid png");
throw image_reader_exception(std::string("failed to read invalid png: '") + error_msg);
}
void user_warning_fn(png_structp png_ptr, png_const_charp warning_msg)