about summary refs log tree commit diff homepage
path: root/lib/Module/KModule.cpp
diff options
context:
space:
mode:
authorCristian Cadar <c.cadar@imperial.ac.uk>2013-12-05 09:15:53 -0800
committerCristian Cadar <c.cadar@imperial.ac.uk>2013-12-05 09:15:53 -0800
commit6d19d31eed55e18709c95363beafe8f679d6070c (patch)
tree945280a95c48b1e89061d6fd303beed1c5692257 /lib/Module/KModule.cpp
parent7c415a118f1bfc291cc6f2479b78db8041db95a4 (diff)
parent29c87addb0bf80baafc5f561cb68509a70a5b1c5 (diff)
downloadklee-6d19d31eed55e18709c95363beafe8f679d6070c.tar.gz
Merge pull request #11 from MartinNowack/Memleaks
Patch Set II - Memleaks
Diffstat (limited to 'lib/Module/KModule.cpp')
-rw-r--r--lib/Module/KModule.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Module/KModule.cpp b/lib/Module/KModule.cpp
index ff13efda..7b23a9c9 100644
--- a/lib/Module/KModule.cpp
+++ b/lib/Module/KModule.cpp
@@ -127,6 +127,10 @@ KModule::~KModule() {
          ie = functions.end(); it != ie; ++it)
     delete *it;
 
+  for (std::map<llvm::Constant*, KConstant*>::iterator it=constantMap.begin(),
+      itE=constantMap.end(); it!=itE;++it)
+    delete it->second;
+
   delete targetData;
   delete module;
 }