27 lines
961 B
Diff
27 lines
961 B
Diff
From: Markus Koschany <apo@debian.org>
|
|
Date: Tue, 25 Apr 2017 14:31:16 +0200
|
|
Subject: initialize entityString
|
|
|
|
Initialize entityString to avoid that ufo2map will randomly segfault when
|
|
compiling the maps.
|
|
|
|
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=860680
|
|
Forwarded: https://sourceforge.net/p/ufoai/code/ci/bae827ba025ff1d3a56b402c27aa84401914acc4/
|
|
---
|
|
src/tools/ufo2map/map.cpp | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/src/tools/ufo2map/map.cpp b/src/tools/ufo2map/map.cpp
|
|
index 47c49f3..f56c55e 100644
|
|
--- a/src/tools/ufo2map/map.cpp
|
|
+++ b/src/tools/ufo2map/map.cpp
|
|
@@ -1227,7 +1227,7 @@ void LoadMapFile (const char* filename)
|
|
/* Set the number of tiles to 1. This is fix for ufo2map right now. */
|
|
mapTiles.numTiles = 1;
|
|
|
|
- char entityString[MAX_TOKEN_CHARS];
|
|
+ char entityString[MAX_TOKEN_CHARS] = "";
|
|
const char* ump = GetUMPName(filename);
|
|
if (ump != nullptr)
|
|
ParseUMP(ump, entityString, false);
|