Ignore '\r' characters when loading the word list

This commit is contained in:
Olivier Teulière 2010-09-10 18:36:36 +00:00
parent 809eb9eb94
commit 170c59481f

View file

@ -151,6 +151,9 @@ void CompDic::loadWordList(const string &iFileName, vector<wstring> &oWordList)
{
line = line.substr(3);
}
// Remove potential \r
if (line[line.size() - 1] == '\r')
line = line.substr(0, line.size() - 1);
// Ignore empty lines
if (line == "")
continue;