summaryrefslogtreecommitdiff
path: root/saveload.c
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2006-08-13 08:51:55 +0000
committerDarkvater <darkvater@openttd.org>2006-08-13 08:51:55 +0000
commit0daa7cdaed81f520e66690136352d890e7d7a623 (patch)
tree88168c8c1eb7220e7472e3adc1a01fc4bfa61e7b /saveload.c
parentb1b0b26fc8a1fc499b1cbe4d3c51f71079bd34fe (diff)
downloadopenttd-0daa7cdaed81f520e66690136352d890e7d7a623.tar.xz
(svn r5873) - Fix a bad comment in r5871, and add a further check for saving strings.
Diffstat (limited to 'saveload.c')
-rw-r--r--saveload.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/saveload.c b/saveload.c
index d1e0cc7db..e4e653600 100644
--- a/saveload.c
+++ b/saveload.c
@@ -516,7 +516,8 @@ static void SlString(void *ptr, uint length, VarType conv)
{
uint len;
assert(GetVarFileType(conv) == SLE_FILE_STRING);
- assert(GetVarMemType(conv) == SLE_VAR_STRB || GetVarMemType(conv) == SLE_VAR_STRQ);
+ assert(GetVarMemType(conv) == SLE_VAR_STRB || GetVarMemType(conv) == SLE_VAR_STRBQ);
+ assert(ptr != NULL);
if (_sl.save) {
len = SlCalcNetStringLen(ptr, length);