aboutsummaryrefslogtreecommitdiffstats
path: root/src/algo_factory
diff options
context:
space:
mode:
Diffstat (limited to 'src/algo_factory')
-rw-r--r--src/algo_factory/algo_factory.cpp1
-rw-r--r--src/algo_factory/algo_factory.h3
2 files changed, 4 insertions, 0 deletions
diff --git a/src/algo_factory/algo_factory.cpp b/src/algo_factory/algo_factory.cpp
index 2f7921ce0..b5d088881 100644
--- a/src/algo_factory/algo_factory.cpp
+++ b/src/algo_factory/algo_factory.cpp
@@ -31,6 +31,7 @@ Algorithm_Factory::~Algorithm_Factory()
*/
void Algorithm_Factory::add_engine(Engine* engine)
{
+ engine->initialize(mutex_factory);
engines.push_back(engine);
}
diff --git a/src/algo_factory/algo_factory.h b/src/algo_factory/algo_factory.h
index fb41b4882..f29683b79 100644
--- a/src/algo_factory/algo_factory.h
+++ b/src/algo_factory/algo_factory.h
@@ -24,6 +24,7 @@ class MessageAuthenticationCode;
class BOTAN_DLL Algorithm_Factory
{
public:
+ Algorithm_Factory(Mutex_Factory& mf) : mutex_factory(mf) {}
~Algorithm_Factory();
void add_engine(class Engine*);
@@ -62,6 +63,8 @@ class BOTAN_DLL Algorithm_Factory
void add_mac(MessageAuthenticationCode* mac);
private:
+ Mutex_Factory& mutex_factory;
+
class Engine* get_engine_n(u32bit) const;
std::vector<class Engine*> engines;