Fix test_malloc_0_null

Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
Ronald Cron 2024-12-05 10:54:33 +01:00
parent bfa03a2c3a
commit 42ba65d892
2 changed files with 2 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* mbedtls_config.h modifier that forces calloc(0) to return NULL.
/* crypto_config.h modifier that forces calloc(0) to return NULL.
* Used for testing.
*/
/*

View File

@ -249,7 +249,7 @@ component_build_tfm () {
component_test_malloc_0_null () {
msg "build: malloc(0) returns NULL (ASan+UBSan build)"
scripts/config.py full
make CC=$ASAN_CC CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"$PWD/tests/configs/user-config-malloc-0-null.h\"' $ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
make CC=$ASAN_CC CFLAGS="'-DTF_PSA_CRYPTO_USER_CONFIG_FILE=\"$PWD/tests/configs/user-config-malloc-0-null.h\"' $ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
msg "test: malloc(0) returns NULL (ASan+UBSan build)"
make test