summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/newgrf.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/newgrf.cpp b/src/newgrf.cpp
index f30b2ef97..7d21ba60b 100644
--- a/src/newgrf.cpp
+++ b/src/newgrf.cpp
@@ -4371,6 +4371,9 @@ static void GRFLoadError(byte *buf, size_t len)
len -= (strlen(data) + 1);
error->data = TranslateTTDPatchCodes(_cur_grffile->grfid, data);
+ } else {
+ grfmsg(7, "GRFLoadError: No message data supplied.");
+ error->data = strdup("");
}
/* Only two parameter numbers can be used in the string. */