forked from github/server
fix bad ship and building names and descriptions in save.
This commit is contained in:
parent
5032d44af4
commit
710811131f
|
@ -1699,12 +1699,18 @@ ship *read_ship(struct gamedata *data)
|
||||||
READ_INT(store, &sh->no);
|
READ_INT(store, &sh->no);
|
||||||
shash(sh);
|
shash(sh);
|
||||||
READ_STR(store, name, sizeof(name));
|
READ_STR(store, name, sizeof(name));
|
||||||
|
if (unicode_utf8_trim(name)!=0) {
|
||||||
|
log_warning("trim ship %s name to '%s'", itoa36(sh->no), name);
|
||||||
|
}
|
||||||
sh->name = _strdup(name);
|
sh->name = _strdup(name);
|
||||||
if (lomem) {
|
if (lomem) {
|
||||||
READ_STR(store, NULL, 0);
|
READ_STR(store, NULL, 0);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
READ_STR(store, name, sizeof(name));
|
READ_STR(store, name, sizeof(name));
|
||||||
|
if (unicode_utf8_trim(name)!=0) {
|
||||||
|
log_warning("trim ship %s info to '%s'", itoa36(sh->no), name);
|
||||||
|
}
|
||||||
sh->display = _strdup(name);
|
sh->display = _strdup(name);
|
||||||
}
|
}
|
||||||
READ_STR(store, name, sizeof(name));
|
READ_STR(store, name, sizeof(name));
|
||||||
|
|
Loading…
Reference in New Issue