forked from github/server
Exploit, ZERSTÖRE strassen mehrfach
This commit is contained in:
parent
e9e35c0e9e
commit
a75accfcd0
|
@ -1273,10 +1273,19 @@ economics(void)
|
|||
|
||||
for (u = r->units; u; u = u->next) {
|
||||
for (S = u->orders; S; S = S->next) {
|
||||
strlist ** slist = &S->next;
|
||||
switch (igetkeyword(S->s, u->faction->locale)) {
|
||||
|
||||
case K_DESTROY:
|
||||
destroy(r, u, S->s);
|
||||
while (*slist) {
|
||||
strlist * scur = *slist;
|
||||
const char * cmd = scur->s;
|
||||
if (igetkeyword(cmd, u->faction->locale)==K_DESTROY) {
|
||||
*slist = scur->next;
|
||||
scur->next = NULL;
|
||||
freestrlist(scur);
|
||||
} else slist = &scur->next;
|
||||
}
|
||||
break;
|
||||
|
||||
case K_GIVE:
|
||||
|
|
Loading…
Reference in New Issue