From fda03ee4ca5f2c3a3548df734bb6f950a3555cde Mon Sep 17 00:00:00 2001 From: Zack Middleton Date: Fri, 10 Jan 2014 12:34:48 -0600 Subject: [PATCH] Fix PNG tRNS length checks --- code/renderercommon/tr_image_png.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/renderercommon/tr_image_png.c b/code/renderercommon/tr_image_png.c index 532454c5..7b6fbada 100644 --- a/code/renderercommon/tr_image_png.c +++ b/code/renderercommon/tr_image_png.c @@ -2274,7 +2274,7 @@ void R_LoadPNG(const char *name, byte **pic, int *width, int *height) { case PNG_ColourType_Grey : { - if(!ChunkHeaderLength == 2) + if(ChunkHeaderLength != 2) { CloseBufferedFile(ThePNG); @@ -2296,7 +2296,7 @@ void R_LoadPNG(const char *name, byte **pic, int *width, int *height) case PNG_ColourType_True : { - if(!ChunkHeaderLength == 6) + if(ChunkHeaderLength != 6) { CloseBufferedFile(ThePNG);