From 4eea98c66b86f444eb07e730ce7a3118dfd092c1 Mon Sep 17 00:00:00 2001 From: erorcun Date: Fri, 2 Jul 2021 23:56:31 +0300 Subject: Peds: Efforts to find the reason of crashes on GCC 7.5.0 * Prevent deleted peds to be in nearPeds list (was always needed, might be unrelated to crashes) * Add asserts to nearPeds and PedIK ctor (crash reasons) * Shouldn't fix reported crashes since they were caused by null peds. --- src/peds/CopPed.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/peds/CopPed.cpp') diff --git a/src/peds/CopPed.cpp b/src/peds/CopPed.cpp index fbfa7249..1efd7733 100644 --- a/src/peds/CopPed.cpp +++ b/src/peds/CopPed.cpp @@ -644,9 +644,6 @@ CCopPed::ProcessControl(void) int numCopsNear = 0; for (int i = 0; i < player->m_numNearPeds; ++i) { CPed *nearPed = player->m_nearPeds[i]; -#ifdef FIX_BUGS - if (nearPed) -#endif if (nearPed->m_nPedType == PEDTYPE_COP && nearPed->m_nPedState != PED_DEAD) ++numCopsNear; } -- cgit v1.2.3