From 115f6d14a0c1e6e108ea4b91179357eedea32173 Mon Sep 17 00:00:00 2001 From: Saracen Date: Sun, 8 Jul 2018 18:51:20 +0100 Subject: Fix bits_per_pixel validation in BMP and TGA loader modules. --- modules/bmp/image_loader_bmp.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/bmp') diff --git a/modules/bmp/image_loader_bmp.cpp b/modules/bmp/image_loader_bmp.cpp index 769119a0dc..919731b52b 100644 --- a/modules/bmp/image_loader_bmp.cpp +++ b/modules/bmp/image_loader_bmp.cpp @@ -53,7 +53,7 @@ Error ImageLoaderBMP::convert_to_image(Ref p_image, err = FAILED; } - if (bits_per_pixel != 24 || bits_per_pixel != 32) { + if (!(bits_per_pixel == 24 || bits_per_pixel == 32)) { err = FAILED; } -- cgit v1.2.3