forked from github/server
fixes duplicate planes (again)
This commit is contained in:
parent
77b292e05a
commit
aaf8668257
2 changed files with 5 additions and 3 deletions
|
@ -1612,7 +1612,7 @@ readgame(const char * filename, int mode, int backup)
|
||||||
int id = store->r_int(store);
|
int id = store->r_int(store);
|
||||||
plane *pl = getplanebyid(id);
|
plane *pl = getplanebyid(id);
|
||||||
if (pl==NULL) {
|
if (pl==NULL) {
|
||||||
calloc(1, sizeof(plane));
|
pl = calloc(1, sizeof(plane));
|
||||||
} else {
|
} else {
|
||||||
log_warning(("the plane with id=%d already exists.\n", id));
|
log_warning(("the plane with id=%d already exists.\n", id));
|
||||||
}
|
}
|
||||||
|
|
|
@ -131,8 +131,10 @@ read_game(const char * filename, const char * mode)
|
||||||
int rv, m = IO_TEXT;
|
int rv, m = IO_TEXT;
|
||||||
if (strcmp(mode, "binary")==0) m = IO_BINARY;
|
if (strcmp(mode, "binary")==0) m = IO_BINARY;
|
||||||
rv = readgame(filename, m, false);
|
rv = readgame(filename, m, false);
|
||||||
log_printf(" - Korrekturen Runde %d\n", turn);
|
if (rv==0) {
|
||||||
korrektur();
|
log_printf(" - Korrekturen Runde %d\n", turn);
|
||||||
|
korrektur();
|
||||||
|
}
|
||||||
return rv;
|
return rv;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue