Changeset - r19584:273c0b244c84
[Not reviewed]
master
0 1 0
frosch - 12 years ago 2012-09-09 15:52:49
frosch@openttd.org
(svn r24515) -Fix: GStexts were compied incompletely when containing certain string codes.
1 file changed with 4 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/game/game_text.cpp
Show inline comments
 
@@ -183,7 +183,10 @@ struct TranslationWriter : LanguageWrite
 

	
 
	void Write(const byte *buffer, size_t length)
 
	{
 
		*this->strings->Append() = strndup((const char*)buffer, length);
 
		char *dest = MallocT<char>(length + 1);
 
		memcpy(dest, buffer, length);
 
		dest[length] = '\0';
 
		*this->strings->Append() = dest;
 
	}
 
};
 

	
0 comments (0 inline, 0 general)