From 8ba58a3d9dd60f1b480cdacb420754e768c4d76e Mon Sep 17 00:00:00 2001 From: Nicolas Adenis-Lamarre Date: Tue, 13 Feb 2018 23:20:23 +0100 Subject: [PATCH] configuration parsing: get_entry must not look into virtual sections only in emu.cfg, when i set rend.WideScreen = 1, its not read. has_entry and get_entry doesn't use the same check, thus while has_entry can return true, get_entry can not return the entry. Signed-off-by: Nicolas Adenis-Lamarre --- core/cfg/ini.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/cfg/ini.cpp b/core/cfg/ini.cpp index 771be4cdc..ca114f2c5 100644 --- a/core/cfg/ini.cpp +++ b/core/cfg/ini.cpp @@ -111,7 +111,7 @@ ConfigSection* ConfigFile::get_section(string name, bool is_virtual) ConfigEntry* ConfigFile::get_entry(string section_name, string entry_name) { ConfigSection* section = this->get_section(section_name, true); - if(section != NULL) + if(section != NULL && section->has_entry(entry_name)) { return section->get_entry(entry_name); }