From 710811131f57ec36ea911ea83664c975ad881b43 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Fri, 11 Nov 2016 22:28:22 +0100 Subject: [PATCH] fix bad ship and building names and descriptions in save. --- src/kernel/save.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/kernel/save.c b/src/kernel/save.c index 528a71808..d063fc8f7 100644 --- a/src/kernel/save.c +++ b/src/kernel/save.c @@ -1699,12 +1699,18 @@ ship *read_ship(struct gamedata *data) READ_INT(store, &sh->no); shash(sh); 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); if (lomem) { READ_STR(store, NULL, 0); } else { 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); } READ_STR(store, name, sizeof(name));