Fixed some log messages

Fixed a crash when no game ini exists


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2690 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
nakeee
2009-03-20 15:01:49 +00:00
parent ed70ca6d48
commit ad76edd157
9 changed files with 40 additions and 44 deletions

View File

@ -74,7 +74,7 @@ const Section* IniFile::GetSection(const char* sectionName) const
Section* IniFile::GetSection(const char* sectionName)
{
for (std::vector<Section>::iterator iter = sections.begin(); iter != sections.end(); ++iter)
if (!strcmp(iter->name.c_str(), sectionName))
if (!strcasecmp(iter->name.c_str(), sectionName))
return (&(*iter));
return 0;
}
@ -171,10 +171,10 @@ std::string* IniFile::GetLine(Section* section, const char* key, std::string* va
return 0;
}
bool IniFile::Exists(const char* sectionName, const char* key)
bool IniFile::Exists(const char* const sectionName, const char* key) const
{
const Section* section = GetSection(sectionName);
const Section* const section = GetSection(sectionName);
if (!section)
return false;