Core/Collision: Fix memory leak

This commit is contained in:
Spp committed 2013-05-30 13:18:29 +02:00
1 parent 36894b09b3
commit 7ccbbdddd8
2 files changed
+40 -42

No files matched your search

@@ -96,7 +96,10 @@ namespace VMAP
std::string mapFileName = getMapFileName(mapId);
StaticMapTree* newTree = new StaticMapTree(mapId, basePath);
if (!newTree->InitMap(mapFileName, this))
{
delete newTree;
return false;
}
instanceTree = iInstanceMapTrees.insert(InstanceTreeMap::value_type(mapId, newTree)).first;
}