From 20ae1e2b4a869d6ea1f9fc217fcd35ea4a379221 Mon Sep 17 00:00:00 2001 From: Kp Date: Sat, 6 Aug 2016 19:55:24 +0000 Subject: [PATCH] Remove useless casts in d1 custom.cpp --- d1x-rebirth/main/custom.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/d1x-rebirth/main/custom.cpp b/d1x-rebirth/main/custom.cpp index 4d4e14fae..2ec96d6fb 100644 --- a/d1x-rebirth/main/custom.cpp +++ b/d1x-rebirth/main/custom.cpp @@ -95,7 +95,7 @@ static int load_pig1(PHYSFS_File *f, unsigned num_bitmaps, unsigned num_sounds, num_custom = 0; - if ((unsigned int)num_bitmaps <= MAX_BITMAP_FILES) // = MAX_BITMAP_FILES || (unsigned int)num_sounds >= MAX_SOUND_FILES) + if (num_bitmaps >= MAX_BITMAP_FILES || + num_sounds >= MAX_SOUND_FILES) return -1; // invalid pig file ci = make_unique(num_bitmaps + num_sounds); custom_info *cip = ci.get();