summaryrefslogtreecommitdiff
path: root/algparam.h
diff options
context:
space:
mode:
authorweidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0>2005-01-20 04:19:35 +0000
committerweidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0>2005-01-20 04:19:35 +0000
commit242d67fb17619670d9b757c442dcf2e26d8478a1 (patch)
tree1f61e8bf59450a028415e5a3f08565a6ceb86afe /algparam.h
parent4b85e6cac0d84aaf65d0695adb137ae956e4e241 (diff)
downloadcryptopp-242d67fb17619670d9b757c442dcf2e26d8478a1.tar.gz
changes done for FIPS-140 lab code drop
git-svn-id: svn://svn.code.sf.net/p/cryptopp/code/trunk/c5@195 57ff6487-cd31-0410-9ec3-f628ee90f5f0
Diffstat (limited to 'algparam.h')
-rw-r--r--algparam.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/algparam.h b/algparam.h
index aa10f65..2f20dd8 100644
--- a/algparam.h
+++ b/algparam.h
@@ -237,10 +237,11 @@ AssignFromHelperClass<T, T> AssignFromHelper(T *pObject, const NameValuePairs &s
// ********************************************************
-// This should allow the linker to discard Integer code if not needed.
-CRYPTOPP_DLL extern bool (*AssignIntToInteger)(const std::type_info &valueType, void *pInteger, const void *pInt);
+// to allow the linker to discard Integer code if not needed.
+typedef bool (CRYPTOPP_API * PAssignIntToInteger)(const std::type_info &valueType, void *pInteger, const void *pInt);
+CRYPTOPP_DLL extern PAssignIntToInteger g_pAssignIntToInteger;
-CRYPTOPP_DLL const std::type_info & IntegerTypeId();
+CRYPTOPP_DLL const std::type_info & CRYPTOPP_API IntegerTypeId();
class CRYPTOPP_DLL AlgorithmParametersBase : public NameValuePairs
{
@@ -292,7 +293,7 @@ public:
void AssignValue(const char *name, const std::type_info &valueType, void *pValue) const
{
// special case for retrieving an Integer parameter when an int was passed in
- if (!(AssignIntToInteger != NULL && typeid(T) == typeid(int) && AssignIntToInteger(valueType, pValue, &m_value)))
+ if (!(g_pAssignIntToInteger != NULL && typeid(T) == typeid(int) && g_pAssignIntToInteger(valueType, pValue, &m_value)))
{
ThrowIfTypeMismatch(name, typeid(T), valueType);
*reinterpret_cast<T *>(pValue) = m_value;