Skip to content

Commit

Permalink
Fix memory leaks in the crypto tests
Browse files Browse the repository at this point in the history
  • Loading branch information
bellgrim committed Feb 8, 2014
1 parent 704eb45 commit 8167f0d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/lib/crypto/test/cryptotest.cpp
Expand Up @@ -33,6 +33,9 @@
#include <cppunit/extensions/TestFactoryRegistry.h>
#include <cppunit/ui/text/TestRunner.h>

#include "CryptoFactory.h"
#include "SecureMemoryRegistry.h"

int main(int /*argc*/, char** /*argv*/)
{
CppUnit::TextUi::TestRunner runner;
Expand All @@ -41,6 +44,9 @@ int main(int /*argc*/, char** /*argv*/)
runner.addTest(registry.makeTest());
bool wasSucessful = runner.run();

CryptoFactory::reset();
SecureMemoryRegistry::reset();

return wasSucessful ? 0 : 1;
}

0 comments on commit 8167f0d

Please sign in to comment.