From 69eabf9d61d98e63d68257525e4dca86b17541d9 Mon Sep 17 00:00:00 2001 From: Jan Matyas Date: Fri, 4 Jun 2021 10:19:29 +0200 Subject: [PATCH] flash/nor/atsamv: fixed "maybe uninitialized" compiler warning This warning about "maybe uninitialized" variable used to pop up on certain versions of GCC. Change-Id: I1cf43b9600885d507afc1dc042322a06751fe146 Signed-off-by: Jan Matyas Reviewed-on: http://openocd.zylin.com/6290 Tested-by: jenkins Reviewed-by: Antonio Borneo --- src/flash/nor/atsamv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/flash/nor/atsamv.c b/src/flash/nor/atsamv.c index a64c2b4cc..efc242395 100644 --- a/src/flash/nor/atsamv.c +++ b/src/flash/nor/atsamv.c @@ -661,7 +661,7 @@ COMMAND_HANDLER(samv_handle_gpnvm_command) return ERROR_COMMAND_SYNTAX_ERROR; } - unsigned v; + unsigned v = 0; if (!strcmp("show", CMD_ARGV[0])) { if (who == -1) { showall: