From 57261615716ece524063dbfca9eabf3e0299ff4c Mon Sep 17 00:00:00 2001 From: tth Date: Thu, 12 Sep 2019 19:33:08 +0200 Subject: [PATCH] better (?) error messages --- funcs/fimg-png.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/funcs/fimg-png.c b/funcs/fimg-png.c index 42473f8d..e1ec15f5 100644 --- a/funcs/fimg-png.c +++ b/funcs/fimg-png.c @@ -64,7 +64,8 @@ fprintf(stderr, "%s opened\n", filename); datasize = png.width * png.height * png.bpp; if ( 3 != png.bpp ) { - fprintf(stderr, "format %d of '%s' not supported\n", + /* I don't really understand this part of the code */ + fprintf(stderr, "bpp format %d of '%s' not supported\n", png.color_type, filename); return -21; } @@ -93,7 +94,7 @@ if (foo) { foo = png_get_data(&png, datas); if (PNG_NO_ERROR != foo) { - fprintf(stderr, "error in '%s' : read png -> %d %s\n", + fprintf(stderr, "error in '%s' :\n\tpng_get_data -> %d = %s\n", __func__, foo, pngerr2str(foo)); return foo; }