Fix set padding call for new versions of OpenSSL

This commit is contained in:
Jonathan Horvath 2020-05-11 18:30:16 -04:00 committed by GitHub
parent daa729c66e
commit 8d632dbb76
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -151,7 +151,7 @@ namespace
int CryptoTransformImpl::setPadding(int padding)
{
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
return EVP_CIPHER_CTX_block_size(_pContext);
return EVP_CIPHER_CTX_set_padding(_pContext, padding);
#else
return EVP_CIPHER_CTX_set_padding(&_context, padding);
#endif