Project

General

Profile

Actions

Bug #317

closed

blocked_find_target_tile() clang analyzer warning about NULL target_unit dereference

Added by Marko Lindqvist 8 months ago. Updated 8 months ago.

Status:
Closed
Priority:
Normal
Category:
General
Target version:
Start date:
03/17/2024
Due date:
% Done:

0%

Estimated time:

Description

S3_1, clang analyzer:

../../../src/common/actions.c:3122:12: warning: Access to field 'tile' results in a dereference of a null pointer (loaded from variable 'target_unit') [core.NullDereference]
3122 | return unit_tile(target_unit); | ^~~~~~~~~~~~~~~~~~~~
../../../src/common/unit.h:388:24: note: expanded from macro 'unit_tile'
388 | #define unit_tile(_pu) ((_pu)->tile) | ^~~~~~~~~~~


Files

Actions

Also available in: Atom PDF