From a2171875a069c2704ee035f1a407eaacee2a3979 Mon Sep 17 00:00:00 2001 From: Evil Eye Date: Sun, 24 Jan 2021 15:15:51 +0100 Subject: [PATCH] Prevent nullptr access --- apps/openmw/mwworld/projectilemanager.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/openmw/mwworld/projectilemanager.cpp b/apps/openmw/mwworld/projectilemanager.cpp index c87f625053..092ce270e9 100644 --- a/apps/openmw/mwworld/projectilemanager.cpp +++ b/apps/openmw/mwworld/projectilemanager.cpp @@ -428,6 +428,9 @@ namespace MWWorld { for (auto& projectileState : mProjectiles) { + if (projectileState.mToDelete) + continue; + auto* projectile = mPhysics->getProjectile(projectileState.mProjectileId); if (!projectile->isActive()) continue;