Actions
Bug #1460
openunit_make_contact() called for dead unit
Start date:
05/27/2025
Due date:
% Done:
0%
Estimated time:
Description
I have an alien ruleset autogame crash in main branch, which I've debugged long enough to know that unit_make_contact() is being called for a dead unit (and at this time utype pointer within unit structure is garbage)
The crash happens in 'unit_has_type_flag(punit, UTYF_FLAGLESS)' call only present in S3_3 and main, but unit_make_contact() has also other unit pointer usages that are not correct with a dead unit.
Files
Updated by Marko Lindqvist 10 days ago
Marko Lindqvist wrote:
unit_make_contact() has also other unit pointer usages that are not correct with a dead unit.
Those are conditional, and should never trigger the issue in the older branches.
Updated by Marko Lindqvist 10 days ago
- File 0085-Fix-crash-on-unit_make_contact-call-with-a-dead-unit.patch 0085-Fix-crash-on-unit_make_contact-call-with-a-dead-unit.patch added
- Status changed from New to In Review
- Assignee set to Marko Lindqvist
- Target version set to 3.3.0
Actions