test: fix build with GCC 11
authorKevin Traynor <ktraynor@redhat.com>
Thu, 20 May 2021 11:06:12 +0000 (12:06 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Thu, 20 May 2021 21:10:22 +0000 (23:10 +0200)
commit50eea2bfa79cc6bfef9014c2e0cb89d5a458969f
treef3aa88297ee3f1161ff6f090c66d300010f2524a
parente32b525aae84023292edf5d2ef2fb78cc340ef14
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 <alialnu@nvidia.com>
Signed-off-by: Kevin Traynor <ktraynor@redhat.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
app/test/test_prefetch.c