keys.c (History_Shutdown): Don't let it write an empty string to history.txt

if no console commands were used.


git-svn-id: svn+ssh://svn.code.sf.net/p/quakespasm/code/trunk@235 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
sezero 2010-06-26 10:50:40 +00:00
parent 72f4ccebb2
commit 43e872d1d1
1 changed files with 2 additions and 5 deletions

View File

@ -731,14 +731,11 @@ void History_Shutdown (void)
i = (i + 1) & (CMDLINES - 1);
} while (i != edit_line && !key_lines[i][1]);
do
while (i != edit_line && key_lines[i][1])
{
// Baker: I commented this line out because byte colored
// text isn't a feature in most ordinary engines.
// fprintf(hf, "%s\n", wcs2str(key_lines[i] + 1));
fprintf(hf, "%s\n", key_lines[i] + 1);
i = (i + 1) & (CMDLINES - 1);
} while (i != edit_line && key_lines[i][1]);
}
fclose(hf);
}
}