Skip to content

Commit a2531b5

Browse files
Ron EldorRon Eldor
authored andcommitted
Fix build error on IAR
IAR fails to build when a variable is initialized with empty curly braces. Added `{ { 0 } }` to fix that.
1 parent c1b6fdc commit a2531b5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

features/cryptocell/FEATURE_CRYPTOCELL310/trng.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
#include "mbedtls/platform.h"
2626

2727
extern mbedtls_platform_context ctx;
28-
static CRYS_RND_WorkBuff_t rndWorkBuff;
28+
static CRYS_RND_WorkBuff_t rndWorkBuff = { { 0 } };
2929

3030
/* Implementation that should never be optimized out by the compiler */
3131
static void mbedtls_zeroize( void *v, size_t n ) {

features/mbedtls/platform/src/platform_alt.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
#if defined(MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT)
2323
#include "mbed_critical.h"
2424

25-
mbedtls_platform_context ctx = { };
25+
mbedtls_platform_context ctx = { { 0 } };
2626

2727
int mbedtls_platform_setup( mbedtls_platform_context *unused_ctx )
2828
{

0 commit comments

Comments
 (0)