mirror of
https://github.com/scummvm/scummvm.git
synced 2026-06-20 05:45:29 +00:00
On switching scenes: Reset _actor->_lastZone in Actor::updateActorsScene(). Actors can store a pointer to a HitZone in _lastZone (see Actor::handleActions()). The HitZone pointed to is held by ObjectMap vm->_scene->_objectMap in array _hitZoneList. When changing scenes the array elements are cleared via ObjectMap::clear() and _lastZone can become stale since only some code paths reset it (e.g. Actor::takeExit()). The stale pointer is then passed to Actor::stepZoneAction() from Actor::handleActions() and dereferenced. Fixes #13661