Fix crash when loading zero-length config files
This was SVN commit r8634.
This commit is contained in:
parent
b13e6ae293
commit
f286ce0b13
@ -352,7 +352,7 @@ bool CConfigDB::Reload(EConfigNamespace ns)
|
||||
if (!next) next=filebufend;
|
||||
|
||||
char *lend=next;
|
||||
if (*(lend-1) == '\r') lend--;
|
||||
if (lend > filebuf && *(lend-1) == '\r') lend--;
|
||||
|
||||
// Send line to parser
|
||||
bool parseOk=parserLine.ParseString(parser, std::string(pos, lend));
|
||||
|
Loading…
Reference in New Issue
Block a user