From 6ce59f0bfefc354242eb9353bba196538dd90882 Mon Sep 17 00:00:00 2001 From: David Lamparter Date: Tue, 10 Dec 2019 17:22:49 +0100 Subject: [PATCH] lib/skiplist: fix gcc-9 used-uninitialized warning Under some circumstances (apparently depends on several optimization flags), gcc-9 throws an used-uninitialized warning for this variable in the skiplist code. Just initialize to NULL. Signed-off-by: David Lamparter --- lib/skiplist.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/skiplist.c b/lib/skiplist.c index dda442580a..6efa2c362d 100644 --- a/lib/skiplist.c +++ b/lib/skiplist.c @@ -608,7 +608,7 @@ void skiplist_test(struct vty *vty) struct skiplist *l; register int i, k; void *keys[sampleSize]; - void *v; + void *v = NULL; zlog_debug("%s: entry", __func__); -- 2.39.5