aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/hmac
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2016-10-21 15:41:04 +0100
committerMatt Caswell <matt@openssl.org>2016-11-04 12:09:46 +0000
commitd0ee717c938cda00bcb13cac2f7e2b162616254b (patch)
tree61d2ba6c0fa3270d6c45178cccf0a6c8ac85d95a /crypto/hmac
parentf0ca8f89f866fd2214241758b8485a462d3f6f01 (diff)
downloadopenssl-d0ee717c938cda00bcb13cac2f7e2b162616254b.tar.gz
Fix style issues in HMAC_size()
Based on review feedback. Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'crypto/hmac')
-rw-r--r--crypto/hmac/hmac.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/crypto/hmac/hmac.c b/crypto/hmac/hmac.c
index a2c9dd9845..ffca891db1 100644
--- a/crypto/hmac/hmac.c
+++ b/crypto/hmac/hmac.c
@@ -119,9 +119,8 @@ int HMAC_Final(HMAC_CTX *ctx, unsigned char *md, unsigned int *len)
size_t HMAC_size(const HMAC_CTX *ctx)
{
int size = EVP_MD_size((ctx)->md);
- if (size < 0)
- return 0;
- return size;
+
+ return (size < 0) ? 0 : size;
}
HMAC_CTX *HMAC_CTX_new(void)