diff options
author | lloyd <[email protected]> | 2006-08-05 11:31:11 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2006-08-05 11:31:11 +0000 |
commit | 1942fdac5ccad80b42f23083e2f8c8e1281989b3 (patch) | |
tree | 69d3ceea09cc1c20dcabf5cfaa5a6fdd3d9bfe5f /src/modules.cpp | |
parent | 1ad291aa76b79216a1560dafe0dbabab4c28b9dd (diff) |
The use_engines flag was not being respected; specifically, if there
were any engines built into the library, they were used no matter what.
Diffstat (limited to 'src/modules.cpp')
-rw-r--r-- | src/modules.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/modules.cpp b/src/modules.cpp index 47a62c13f..43d9d0f90 100644 --- a/src/modules.cpp +++ b/src/modules.cpp @@ -188,17 +188,20 @@ std::vector<Engine*> Builtin_Modules::engines() const { std::vector<Engine*> engines; + if(use_engines) + { #if defined(BOTAN_EXT_ENGINE_AEP) - engines.push_back(new AEP_Engine); + engines.push_back(new AEP_Engine); #endif #if defined(BOTAN_EXT_ENGINE_GNU_MP) - engines.push_back(new GMP_Engine); + engines.push_back(new GMP_Engine); #endif #if defined(BOTAN_EXT_ENGINE_OPENSSL) - engines.push_back(new OpenSSL_Engine); + engines.push_back(new OpenSSL_Engine); #endif + } engines.push_back(new Default_Engine); @@ -217,7 +220,8 @@ Charset_Transcoder* Builtin_Modules::transcoder() const * Builtin_Modules Constructor * *************************************************/ Builtin_Modules::Builtin_Modules(const InitializerOptions& args) : - should_lock(args.secure_memory()) + should_lock(args.secure_memory()), + use_engines(args.use_engines()) { } |