Follow-up Comment #5, bug #21693 (project freeciv):

Reproduced with S2_4 r24519 from file #20117 (haven't tried the others).

Moving unit is Willy Brandt's Archers [l tgt="unit" id=274/], into Dortmund.
Server is considering autoattack from pirates in boat adjacent to city.

In my case it's trying to work out which of Musketeers [l tgt="unit" id=393/]
and Barbarian Leader [l tgt="unit" id=394/] is the better attacker. But
neither can attack from boats so get_defender() returns NULL, which
compare_units() isn't prepared for.

Think this might have been caused by patch #4445 (post 2.4.2): when building
the autoattack list, unit_survive_autoattack() treats return from
can_unit_attack_unit_at_tile() as boolean, but it's now an enum.

(In passing: I think the return from can_unit_attack_any_at_tile() is now
different if passed the empty list?)


Reply to this item at:


  Message sent via/by Gna!

Freeciv-dev mailing list

Reply via email to