const unsigned char *salt, unsigned int saltlen,
const unsigned char *pass, int passlen)
{
- EVP_MD_CTX *mctx = EVP_MD_CTX_create();;
+ EVP_MD_CTX *mctx = EVP_MD_CTX_new();;
int rv = 1;
if (mctx == NULL
|| !EVP_DigestInit_ex(mctx, EVP_sha1(), NULL)
|| !EVP_DigestFinal_ex(mctx, key, NULL))
rv = 0;
- EVP_MD_CTX_destroy(mctx);
+ EVP_MD_CTX_free(mctx);
return rv;
}