I believe this is the evil bug that's been corrupting my SAVEGAME.INF. (I

can't reproduce the problem under Windows though.)

svn-id: r11996
This commit is contained in:
Torbjörn Andersson 2003-12-28 15:02:21 +00:00
parent db5a2ba1c8
commit 302c9f72fc

View File

@ -440,7 +440,7 @@ void SwordControl::writeSavegameDescriptions(void) {
outf = mgr->open_savefile("SAVEGAME.INF", _savePath, SAVEFILE_WRITE);
// if the player accidently clicked the last slot and then deselected it again,
// we'd still have _saveFiles == 64, so get rid of the empty end.
while (strlen(_saveNames[_saveFiles] - 1) == 0)
while (strlen(_saveNames[_saveFiles - 1]) == 0)
_saveFiles--;
for (uint8 cnt = 0; cnt < _saveFiles; cnt++) {
outf->write(_saveNames[cnt], strlen(_saveNames[cnt]));