diff options
author | lloyd <[email protected]> | 2008-11-23 21:17:20 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2008-11-23 21:17:20 +0000 |
commit | c243688f6062cf4577610d8ef71ba0ec60a932e2 (patch) | |
tree | 1c9f21adcdffc476f520255623016466ec4d5b96 /src/libstate/lookup.cpp | |
parent | dfd6e089a95f2c7a7179b366afbbbebf3fedc576 (diff) |
Add an Algorithm_Factory& argument to Engine::get_cipher to avoid a
dependency on libstate.h
Diffstat (limited to 'src/libstate/lookup.cpp')
-rw-r--r-- | src/libstate/lookup.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libstate/lookup.cpp b/src/libstate/lookup.cpp index 24a8a8ecd..adf3d80ed 100644 --- a/src/libstate/lookup.cpp +++ b/src/libstate/lookup.cpp @@ -249,11 +249,13 @@ u32bit keylength_multiple_of(const std::string& name) Keyed_Filter* get_cipher(const std::string& algo_spec, Cipher_Dir direction) { - Algorithm_Factory::Engine_Iterator i(global_state().algorithm_factory()); + Algorithm_Factory& af = global_state().algorithm_factory(); + + Algorithm_Factory::Engine_Iterator i(af); while(Engine* engine = i.next()) { - Keyed_Filter* algo = engine->get_cipher(algo_spec, direction); + Keyed_Filter* algo = engine->get_cipher(algo_spec, direction, af); if(algo) return algo; } |