[openssl-commits] [openssl] master update
Viktor Dukhovni
viktor at openssl.org
Sat Nov 21 10:28:04 UTC 2015
The branch master has been updated
via 5c649375dd756dcd0b0c81a14a04cd8e87f198c1 (commit)
from 22a34c2fab39c38cac4a22a0e15ab9a1fd98f57c (commit)
- Log -----------------------------------------------------------------
commit 5c649375dd756dcd0b0c81a14a04cd8e87f198c1
Author: Viktor Dukhovni <openssl-users at dukhovni.org>
Date: Sat Nov 21 00:59:07 2015 -0500
Good hygiene with size_t output argument.
Though the callers check the function return value and ignore the
size_t output argument on failure, it is still often not ideal to
store (-1) in size_t on error. That might signal an unduly large
buffer. Instead set the size_t to 0, to indicate no space.
Reviewed-by: Richard Levitte <levitte at openssl.org>
-----------------------------------------------------------------------
Summary of changes:
ssl/s3_cbc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ssl/s3_cbc.c b/ssl/s3_cbc.c
index 5225222..177f6d7 100644
--- a/ssl/s3_cbc.c
+++ b/ssl/s3_cbc.c
@@ -278,7 +278,7 @@ int ssl3_cbc_digest_record(const EVP_MD_CTX *ctx,
*/
OPENSSL_assert(0);
if (md_out_size)
- *md_out_size = -1;
+ *md_out_size = 0;
return 0;
}
More information about the openssl-commits
mailing list