navi() reads the ships into a list. When the ships get interdicted,
and lack flak shells, ac_shipflak() tries to get one and updates the
ship. When the ship in the list is later written back, e.g. to apply
interdiction damage, the flak shell is wiped out, and we get a seqno
mismatch oops.
Disable automatic flak shell supply in ac_ship_flak() for now. This
is related to commit
f7d61817, which disabled automatic supply of
shells in ac_doflak() and shp_missile_defense().
gun = shp_usable_guns(&ship);
if (gun) {
shell = ship.shp_item[I_SHELL];
+#if 0
+ /*
+ * FIXME if this supplies the ship while it is being
+ * interdicted, we get a seqno mismatch when interdiction
+ * damage is applied.
+ */
if (shell <= 0) {
shell = supply_commod(ship.shp_own, ship.shp_x, ship.shp_y,
I_SHELL, 1);
ship.shp_item[I_SHELL] = shell;
putship(ship.shp_uid, &ship);
}
+#endif
}
if (gun == 0 || shell == 0)
continue;