diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2000-06-21 02:25:30 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2000-06-21 02:25:30 +0000 |
commit | 130832150c1313824868b154cccda3ace88fa950 (patch) | |
tree | f2b0eac7c3740a8b85f52210b42dc5dc9352557b /crypto/evp/evp_pbe.c | |
parent | 7ef8206859f9a52f48e817c023c744fe00e82c5d (diff) | |
download | openssl-130832150c1313824868b154cccda3ace88fa950.tar.gz |
Fixes for Win32 build.
This is mostly a work around for the old VC++ problem
that it treats func() as func(void).
Various prototypes had been added to 'compare' function
pointers that triggered this. This could be fixed by removing
the prototype, adding function pointer casts to every call or
changing the passed function to use the expected arguments.
I mostly did the latter.
The mkdef.pl script was modified to remove the typesafe
functions which no longer exist.
Oh and some functions called OPENSSL_freeLibrary() were
changed back to FreeLibrary(), wonder how that happened :-)
Diffstat (limited to 'crypto/evp/evp_pbe.c')
-rw-r--r-- | crypto/evp/evp_pbe.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/crypto/evp/evp_pbe.c b/crypto/evp/evp_pbe.c index 229ac673a7..224a422b12 100644 --- a/crypto/evp/evp_pbe.c +++ b/crypto/evp/evp_pbe.c @@ -104,8 +104,9 @@ int EVP_PBE_CipherInit (ASN1_OBJECT *pbe_obj, const char *pass, int passlen, return 1; } -static int pbe_cmp (EVP_PBE_CTL **pbe1, EVP_PBE_CTL **pbe2) +static int pbe_cmp(const char * const *a, const char * const *b) { + EVP_PBE_CTL **pbe1 = (EVP_PBE_CTL **) a, **pbe2 = (EVP_PBE_CTL **)b; return ((*pbe1)->pbe_nid - (*pbe2)->pbe_nid); } @@ -115,7 +116,7 @@ int EVP_PBE_alg_add (int nid, EVP_CIPHER *cipher, EVP_MD *md, EVP_PBE_KEYGEN *keygen) { EVP_PBE_CTL *pbe_tmp; - if (!pbe_algs) pbe_algs = sk_new ((int (*)())pbe_cmp); + if (!pbe_algs) pbe_algs = sk_new(pbe_cmp); if (!(pbe_tmp = (EVP_PBE_CTL*) OPENSSL_malloc (sizeof(EVP_PBE_CTL)))) { EVPerr(EVP_F_EVP_PBE_ALG_ADD,ERR_R_MALLOC_FAILURE); return 0; |