Fix crash in config file loader
This commit is contained in:
parent
2e275c4599
commit
2a939e6d9b
@ -280,7 +280,7 @@ void ConfigFile::LoadFile(Reader *r, const char *name){
|
||||
}
|
||||
key=l.substr(0,i); ConfigEntry::trim(key);
|
||||
val=l.substr(i+1); comment = ConfigEntry::trimCommented(val);
|
||||
if(val[0]=='"' && *val.rbegin()=='"') val=val.substr(1, val.size()-2);
|
||||
if(val.size() > 0 && val[0]=='"' && *val.rbegin()=='"') val=val.substr(1, val.size()-2);
|
||||
|
||||
ConfigEntry e(line, section, key, val);
|
||||
e.comment = comment;
|
||||
|
Loading…
Reference in New Issue
Block a user