diff options
author | weidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0> | 2002-11-19 20:44:40 +0000 |
---|---|---|
committer | weidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0> | 2002-11-19 20:44:40 +0000 |
commit | 7c32afc0c2a23e39ea7fe3dce9c718c77f758bb7 (patch) | |
tree | e6892323cff57a9ed487d204231a5ccec3a3eac5 /strciphr.h | |
parent | 6ea2796d91ca021f7e8846a1dda8e83edf4b4420 (diff) | |
download | cryptopp-7c32afc0c2a23e39ea7fe3dce9c718c77f758bb7.tar.gz |
fixed to compile with Intel compiler
git-svn-id: svn://svn.code.sf.net/p/cryptopp/code/trunk/c5@17 57ff6487-cd31-0410-9ec3-f628ee90f5f0
Diffstat (limited to 'strciphr.h')
-rw-r--r-- | strciphr.h | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -36,9 +36,10 @@ NAMESPACE_BEGIN(CryptoPP) template <class POLICY_INTERFACE, class BASE = Empty> class AbstractPolicyHolder : public BASE { -protected: +public: typedef POLICY_INTERFACE PolicyInterface; +protected: virtual const POLICY_INTERFACE & GetPolicy() const =0; virtual POLICY_INTERFACE & AccessPolicy() =0; }; @@ -130,9 +131,9 @@ public: bool IsRandomAccess() const {return GetPolicy().IsRandomAccess();} void Seek(dword position); -protected: typedef typename BASE::PolicyInterface PolicyInterface; +protected: void UncheckedSetKey(const NameValuePairs ¶ms, const byte *key, unsigned int length); unsigned int GetBufferByteSize(const PolicyInterface &policy) const {return policy.GetBytesPerIteration() * policy.GetIterationsToBuffer();} @@ -220,9 +221,9 @@ public: bool IsRandomAccess() const {return false;} bool IsSelfInverting() const {return false;} -protected: typedef typename BASE::PolicyInterface PolicyInterface; +protected: virtual void CombineMessageAndShiftRegister(byte *output, byte *reg, const byte *message, unsigned int length) =0; void UncheckedSetKey(const NameValuePairs ¶ms, const byte *key, unsigned int length); @@ -262,7 +263,7 @@ public: UncheckedSetKey(params, key, length); } - Clonable * Clone() {return new SymmetricCipherFinalTemplate<BASE, INFO>(*this);} + Clonable * Clone() const {return static_cast<SymmetricCipher *>(new SymmetricCipherFinalTemplate<BASE, INFO>(*this));} }; template <class S> |