commit | aa464ef23a49e386515e5245c444f202e45e2e4f | [log] [tgz] |
---|---|---|
author | Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> | Fri Jul 21 14:21:53 2017 +0100 |
committer | Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> | Fri Jul 21 14:27:41 2017 +0100 |
tree | 011481952e8605105b8c9ee8f1499f7a26607d77 | |
parent | b2b063ff3538f1a8f8a027009712e67b5a5fc4a9 [diff] [blame] |
Fix indentation and add goto cleanup; stmt
diff --git a/library/md.c b/library/md.c index 625b34c..cec4243 100644 --- a/library/md.c +++ b/library/md.c
@@ -436,7 +436,8 @@ goto cleanup; if( ( ret = mbedtls_md_hmac_update( &ctx, input, ilen ) ) != 0 ) goto cleanup; - ret = mbedtls_md_hmac_finish( &ctx, output ); + if( ( ret = mbedtls_md_hmac_finish( &ctx, output ) ) != 0 ) + goto cleanup; cleanup: mbedtls_md_free( &ctx );