diff options
-rw-r--r-- | doc/man3/EVP_EncryptInit.pod | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/man3/EVP_EncryptInit.pod b/doc/man3/EVP_EncryptInit.pod index 46e6a57d4b..66e1ffb688 100644 --- a/doc/man3/EVP_EncryptInit.pod +++ b/doc/man3/EVP_EncryptInit.pod @@ -552,6 +552,7 @@ Encrypt a string using IDEA: if (!EVP_EncryptUpdate(ctx, outbuf, &outlen, intext, strlen(intext))) { /* Error */ + EVP_CIPHER_CTX_free(ctx); return 0; } /* @@ -560,6 +561,7 @@ Encrypt a string using IDEA: */ if (!EVP_EncryptFinal_ex(ctx, outbuf + outlen, &tmplen)) { /* Error */ + EVP_CIPHER_CTX_free(ctx); return 0; } outlen += tmplen; @@ -571,6 +573,10 @@ Encrypt a string using IDEA: * NULs. */ out = fopen(outfile, "wb"); + if (out == NULL) { + /* Error */ + return 0; + } fwrite(outbuf, 1, outlen, out); fclose(out); return 1; |