mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-12-24 17:41:01 +03:00
Fix IAR control bypasses initialisation warning
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
This commit is contained in:
@@ -681,6 +681,7 @@ int mbedtls_sha256_finish(mbedtls_sha256_context *ctx,
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
uint32_t used;
|
||||
uint32_t high, low;
|
||||
int truncated = 0;
|
||||
|
||||
/*
|
||||
* Add padding: 0x80 then 0x00 until 8 bytes remain for the length
|
||||
@@ -728,7 +729,6 @@ int mbedtls_sha256_finish(mbedtls_sha256_context *ctx,
|
||||
MBEDTLS_PUT_UINT32_BE(ctx->state[5], output, 20);
|
||||
MBEDTLS_PUT_UINT32_BE(ctx->state[6], output, 24);
|
||||
|
||||
int truncated = 0;
|
||||
#if defined(MBEDTLS_SHA224_C)
|
||||
truncated = ctx->is224;
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user