diff options
Diffstat (limited to 'engines/m4/converse.cpp')
-rw-r--r-- | engines/m4/converse.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/m4/converse.cpp b/engines/m4/converse.cpp index 11bc165811..af26a86313 100644 --- a/engines/m4/converse.cpp +++ b/engines/m4/converse.cpp @@ -858,8 +858,8 @@ void Converse::loadConversationMads(const char *convName) { if (buffer[curPos - 1] == '\0') { // end of string //printf("%s\n", buffer); - buf = new char[strlen(buffer)]; - sprintf(buf, "%s", buffer); + buf = new char[strlen(buffer) + 1]; + strcpy(buf, buffer); _convStrings.push_back(buf); curPos = 0; *buffer = 0; |