summaryrefslogtreecommitdiff
path: root/src/resources/mapdb.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources/mapdb.cpp')
-rw-r--r--src/resources/mapdb.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/resources/mapdb.cpp b/src/resources/mapdb.cpp
index 4050a5072..0b553e35d 100644
--- a/src/resources/mapdb.cpp
+++ b/src/resources/mapdb.cpp
@@ -45,7 +45,10 @@ void MapDB::load()
xmlNodePtr root = doc->rootNode();
if (!root)
+ {
+ delete doc;
return;
+ }
for_each_xml_child_node(node, root)
{