Fixed wrong condition in library.cpp

This commit is contained in:
PKEuS 2015-01-10 20:51:14 +01:00
parent b30f03709a
commit d019b7f9a6
1 changed files with 1 additions and 1 deletions

View File

@ -398,7 +398,7 @@ Library::Error Library::load(const tinyxml2::XMLDocument &doc)
const char* const inherits = node->Attribute("inherits");
if (inherits) {
std::map<std::string, Container>::const_iterator i = containers.find(inherits);
if (inherits)
if (i != containers.end())
container = i->second; // Take values from parent and overwrite them if necessary
else
return Error(BAD_ATTRIBUTE_VALUE, inherits);