[PATCH] examples/fips_validation: fix dangling pointer for SHA test
Ji, Kai
kai.ji at intel.com
Thu Nov 27 17:51:41 CET 2025
Acked-by: Kai Ji <kai.ji at intel.com>
________________________________
From: Finn, Emma <emma.finn at intel.com>
Sent: 28 August 2025 10:28
To: Gowrishankar Muthukrishnan <gmuthukrishn at marvell.com>
Cc: dev at dpdk.org <dev at dpdk.org>; Ji, Kai <kai.ji at intel.com>; Finn, Emma <emma.finn at intel.com>
Subject: [PATCH] examples/fips_validation: fix dangling pointer for SHA test
Set vector pointer to NULL after free to avoid calling rte_free()
on the same pointer twice in some cases.
Signed-off-by: Emma Finn <emma.finn at intel.com>
---
examples/fips_validation/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/examples/fips_validation/main.c b/examples/fips_validation/main.c
index f21826e9d7..60ee9f8dd4 100644
--- a/examples/fips_validation/main.c
+++ b/examples/fips_validation/main.c
@@ -2612,7 +2612,7 @@ fips_mct_sha_test(void)
rte_free(md[i].val);
rte_free(vec.pt.val);
-
+ vec.pt.val = NULL;
rte_free(val.val);
return 0;
}
--
2.34.1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mails.dpdk.org/archives/dev/attachments/20251127/ae5cc1db/attachment.htm>
More information about the dev
mailing list