diff --git a/game/game_io.cpp b/game/game_io.cpp index 68810bb..b86ed2d 100644 --- a/game/game_io.cpp +++ b/game/game_io.cpp @@ -159,7 +159,7 @@ Game* Game::gameLoadFormat_14(FILE *fin, const Dictionary& iDic) break; //debug("%s)", token); - strncat(pos, token, sizeof(pos)); + strncat(pos, token, sizeof(pos) - strlen(pos) - 1); if ((ret = pGame->play(convertToWc(pos), convertToWc(word)))) {