aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2016-04-25 13:56:44 +0100
committerMatt Caswell <matt@openssl.org>2016-06-16 09:50:48 +0100
commitcf3404fcc77aaf592c95326cbdd25612a8af6878 (patch)
treef85b17508cae4736176c27266148a23f64a7571a /doc
parent2ac6115d9ee35308300b82d96078d03d81e7d320 (diff)
downloadopenssl-cf3404fcc77aaf592c95326cbdd25612a8af6878.tar.gz
Change the return type of EVP_EncodeUpdate
Previously EVP_EncodeUpdate returned a void. However there are a couple of error conditions that can occur. Therefore the return type has been changed to an int, with 0 indicating error and 1 indicating success. Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'doc')
-rw-r--r--doc/crypto/EVP_EncodeInit.pod9
1 files changed, 6 insertions, 3 deletions
diff --git a/doc/crypto/EVP_EncodeInit.pod b/doc/crypto/EVP_EncodeInit.pod
index f65322617d..4f62e71ec6 100644
--- a/doc/crypto/EVP_EncodeInit.pod
+++ b/doc/crypto/EVP_EncodeInit.pod
@@ -15,8 +15,8 @@ routines
void EVP_ENCODE_CTX_free(EVP_ENCODE_CTX *ctx);
int EVP_ENCODE_CTX_num(EVP_ENCODE_CTX *ctx);
void EVP_EncodeInit(EVP_ENCODE_CTX *ctx);
- void EVP_EncodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl,
- const unsigned char *in, int inl);
+ int EVP_EncodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl,
+ const unsigned char *in, int inl);
void EVP_EncodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl);
int EVP_EncodeBlock(unsigned char *t, const unsigned char *f, int n);
@@ -66,7 +66,8 @@ any remainder). This gives the number of blocks of data that will be processed.
Ensure the output buffer contains 65 bytes of storage for each block, plus an
additional byte for a NUL terminator. EVP_EncodeUpdate() may be called
repeatedly to process large amounts of input data. In the event of an error
-EVP_EncodeUpdate() will set B<*outl> to 0.
+EVP_EncodeUpdate() will set B<*outl> to 0 and return 0. On success 1 wil be
+returned.
EVP_EncodeFinal() must be called at the end of an encoding operation. It will
process any partial block of data remaining in the B<ctx> object. The output
@@ -129,6 +130,8 @@ object or NULL on error.
EVP_ENCODE_CTX_num() returns the number of bytes pending encoding or decoding in
B<ctx>.
+EVP_EncodeUpdate() returns 0 on error or 1 on success.
+
EVP_EncodeBlock() returns the number of bytes encoded excluding the NUL
terminator.