summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/alphagen.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/alphagen.c b/src/alphagen.c
index 384e70b..6ced487 100644
--- a/src/alphagen.c
+++ b/src/alphagen.c
@@ -317,7 +317,7 @@ bool image_read_png(char *file_name, struct image *img)
bit_depth = png_get_bit_depth(png_ptr, info_ptr);
color_type = png_get_color_type(png_ptr, info_ptr);
- if (color_type != PNG_COLOR_TYPE_RGB && bit_depth != 8)
+ if (color_type != PNG_COLOR_TYPE_RGB || bit_depth != 8)
return false;
if (!image_init(img, width, height, 3))