Use a signed value to check return value of do_cipher().
This commit is contained in:
parent
beb895083c
commit
4fc02f1229
@ -368,11 +368,11 @@ int EVP_EncryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl)
|
|||||||
|
|
||||||
if (ctx->cipher->flags & EVP_CIPH_FLAG_CUSTOM_CIPHER)
|
if (ctx->cipher->flags & EVP_CIPH_FLAG_CUSTOM_CIPHER)
|
||||||
{
|
{
|
||||||
i = ctx->cipher->do_cipher(ctx, out, NULL, 0);
|
ret = ctx->cipher->do_cipher(ctx, out, NULL, 0);
|
||||||
if (i < 0)
|
if (ret < 0)
|
||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
*outl = i;
|
*outl = ret;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user