diff options
author | Christian Pointner <equinox@anytun.org> | 2009-01-15 12:27:06 +0000 |
---|---|---|
committer | Christian Pointner <equinox@anytun.org> | 2009-01-15 12:27:06 +0000 |
commit | 86891c4b1884a53bcd6e6bd021eb2a7b3987ab28 (patch) | |
tree | 828736cf5477351b488b02ad722b2442fbee335e /src/keyDerivation.cpp | |
parent | small cleanup (diff) |
small cleanup
Diffstat (limited to 'src/keyDerivation.cpp')
-rw-r--r-- | src/keyDerivation.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/keyDerivation.cpp b/src/keyDerivation.cpp index 46c1568..fcb3001 100644 --- a/src/keyDerivation.cpp +++ b/src/keyDerivation.cpp @@ -198,6 +198,11 @@ bool AesIcmKeyDerivation::generate(kd_dir dir, satp_prf_label label, seq_nr_t se { ReadersLock lock(mutex_); +#ifndef USE_SSL_CRYPTO + if(!handle_[dir]) + return false; +#endif + seq_nr_t r; calcCtr(dir, &r, label, seq_nr); // TODO: return stored key @@ -212,7 +217,6 @@ bool AesIcmKeyDerivation::generate(kd_dir dir, satp_prf_label label, seq_nr_t se // return false; // } - #ifndef USE_SSL_CRYPTO gcry_error_t err = gcry_cipher_reset(handle_[dir]); if(err) { |