Simplify conditions in bfirst_search_try()

git-svn-id: https://svn.eduke32.com/eduke32@7568 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2019-04-10 09:30:45 +00:00 committed by Christoph Oelckers
parent b7d06c0bd8
commit c8eb1d0368

View file

@ -10950,9 +10950,7 @@ void bfirst_search_init(int16_t * const list, uint8_t * const bitmap, int32_t *
void bfirst_search_try(int16_t * const list, uint8_t * const bitmap, int32_t * const eltnumptr, int const elt)
{
if (elt < 0)
return;
else if (bitmap_test(bitmap, elt)==0)
if (elt >= 0 && bitmap_test(bitmap, elt)==0)
{
bitmap_set(bitmap, elt);
list[(*eltnumptr)++] = elt;