diff options
author | lloyd <[email protected]> | 2008-11-12 21:36:27 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2008-11-12 21:36:27 +0000 |
commit | 8dbcc47cacf7a9dba7c926bc4553b8e2a5114283 (patch) | |
tree | 66284f063fcc285f1dffb4348a32c8ef5f5e5ce6 /src/algo_factory | |
parent | d226f7f054ad22352b1e99826218712bdd63a508 (diff) |
Add comment about non-obvious but vital side effect
Diffstat (limited to 'src/algo_factory')
-rw-r--r-- | src/algo_factory/algo_factory.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/algo_factory/algo_factory.cpp b/src/algo_factory/algo_factory.cpp index 043e21459..4ff5bb2b6 100644 --- a/src/algo_factory/algo_factory.cpp +++ b/src/algo_factory/algo_factory.cpp @@ -126,6 +126,11 @@ Engine* Algorithm_Factory::get_engine_n(u32bit n) const std::vector<std::string> Algorithm_Factory::providers_of(const std::string& algo_spec) { + /* The checks with if(prototype_X(algo_spec)) have the effect of + forcing a full search, since otherwise there might not be any + providers at all in the cache. + */ + if(prototype_block_cipher(algo_spec)) return block_cipher_cache.providers_of(algo_spec); else if(prototype_stream_cipher(algo_spec)) |