]> git.pond.sub.org Git - empserver/commit
Fix a bug in attack that could wipe out land unit updates
authorMarkus Armbruster <armbru@pond.sub.org>
Sun, 8 Mar 2009 10:54:04 +0000 (11:54 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Sun, 8 Mar 2009 10:54:04 +0000 (11:54 +0100)
commite03eaeae23b8b6bc37f4c434f37652ca8c13d0b5
tree017c1660e304deb238613445654e516428d9039f
parent6b75c21e3c2835641c1781f5dcc3837ea25c1c6a
Fix a bug in attack that could wipe out land unit updates

A victorious attacker can move attacking land units into the newly
conquered sector or leave them behind.  Normally, the player is asked
what to do, but when the land unit's army has already been told to
stay behind, or the command has been aborted, the land unit stays
behind without asking.  In that case, a copy of the land unit made
right after the victory was written back.  Any updates since the
victory were wiped out, triggering a seqno mismatch oops.

Fix by moving the re-read of the land unit in ask_move_in() out of the
prompt conditional.
src/lib/subs/attsub.c