forked from github/server
Revert "general check for sf->faction's validity"
This reverts commit f18b5ea7d2
.
This commit is contained in:
parent
f18b5ea7d2
commit
491e5faed9
|
@ -1346,16 +1346,11 @@ void writefaction(struct gamedata *data, const faction * f)
|
|||
WRITE_SECTION(data->store);
|
||||
|
||||
for (sf = f->allies; sf; sf = sf->next) {
|
||||
if (sf->faction != NULL) {
|
||||
int no = sf->faction->no;
|
||||
int status = alliedfaction(NULL, f, sf->faction, HELP_ALL);
|
||||
if (status != 0) {
|
||||
WRITE_INT(data->store, no);
|
||||
WRITE_INT(data->store, sf->status);
|
||||
}
|
||||
}
|
||||
else {
|
||||
log_error("NULL-pointer in ally-struct for faction '%s'.", f->no);
|
||||
int no = (sf->faction != NULL) ? sf->faction->no : 0;
|
||||
int status = alliedfaction(NULL, f, sf->faction, HELP_ALL);
|
||||
if (status != 0) {
|
||||
WRITE_INT(data->store, no);
|
||||
WRITE_INT(data->store, sf->status);
|
||||
}
|
||||
}
|
||||
WRITE_INT(data->store, 0);
|
||||
|
|
Loading…
Reference in New Issue