From 8c36fcf64ce05b10a094e7ec63c029fc52965b4c Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Wed, 27 Jun 2007 09:32:42 +0000 Subject: Path #1743892: "Fix for segmentation fault in theming code" svn-id: r27743 --- gui/theme-config.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'gui') diff --git a/gui/theme-config.cpp b/gui/theme-config.cpp index 3bac51a8fe..8da2be99e1 100644 --- a/gui/theme-config.cpp +++ b/gui/theme-config.cpp @@ -617,16 +617,16 @@ void Theme::processResSection(Common::ConfigFile &config, const String &name, bo if (iterk->key == "use") { if (iterk->value == name) error("Theme section [%s]: cannot use itself", name.c_str()); - if (!config.hasSection(name)) - error("Undefined use of section [%s]", name.c_str()); + if (!config.hasSection(iterk->value)) + error("Undefined use of section [%s]", iterk->value.c_str()); processResSection(config, iterk->value, true); continue; } if (iterk->key == "useAsIs") { if (iterk->value == name) error("Theme section [%s]: cannot use itself", name.c_str()); - if (!config.hasSection(name)) - error("Undefined use of section [%s]", name.c_str()); + if (!config.hasSection(iterk->value)) + error("Undefined use of section [%s]", iterk->value.c_str()); processResSection(config, iterk->value); continue; } -- cgit v1.2.3