From: Kevin Traynor Date: Thu, 20 May 2021 11:06:12 +0000 (+0100) Subject: test: fix build with GCC 11 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=50eea2bfa79cc6bfef9014c2e0cb89d5a458969f;p=dpdk.git test: fix build with GCC 11 GCC 11 complains that 'a' is uninitialized. ../dpdk/app/test/test_prefetch.c: In function 'test_prefetch': ../dpdk/app/test/test_prefetch.c:25:9: error: 'a' may be used uninitialized [-Werror=maybe-uninitialized] 25 | rte_prefetch0(&a); | ^~~~~~~~~~~~~~~~~ Fix by initializing 'a'. Bugzilla ID: 714 Fixes: af75078fece3 ("first public release") Cc: stable@dpdk.org Reported-by: Ali Alnubani Signed-off-by: Kevin Traynor Tested-by: Ali Alnubani Reviewed-by: David Marchand --- diff --git a/app/test/test_prefetch.c b/app/test/test_prefetch.c index 5489885b51..7b4a8e4144 100644 --- a/app/test/test_prefetch.c +++ b/app/test/test_prefetch.c @@ -20,7 +20,7 @@ static int test_prefetch(void) { - int a; + int a = 0; rte_prefetch0(&a); rte_prefetch1(&a);