Really fix bomb not to wipe out plane updates
authorMarkus Armbruster <armbru@pond.sub.org>
Tue, 10 Mar 2009 11:51:44 +0000 (12:51 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Tue, 10 Mar 2009 11:51:44 +0000 (12:51 +0100)
Commit f07e6901 didn't fix it completely.

src/lib/commands/bomb.c

index 0a69c0d5b7096cab9c43f8080bdd8634add7275f..f959e06d77a19fd0c3ee5698649ba2993e384324 100644 (file)
@@ -95,6 +95,8 @@ bomb(void)
     int wantflags;
     struct sctstr ap_sect;
     char mission;
+    struct plist *plp;
+    struct emp_qelem *qp, *next;
     int rel;
     struct natstr *natp;
     char buf[1024];
@@ -150,6 +152,11 @@ bomb(void)
        switch (mission) {
        case 'p':
            pin_bomb(&bomb_list, &target);
+           for (qp = bomb_list.q_forw; qp != &bomb_list; qp = next) {
+               next = qp->q_forw;
+               plp = (struct plist *)qp;
+               changed_plane_aborts(plp);
+           }
            break;
        case 's':
            if (opt_SLOW_WAR) {