From c571aeae6f54288c627dfcd04d843d848ab7d1d4 Mon Sep 17 00:00:00 2001 From: Zdenek Kabelac Date: Mon, 21 Nov 2011 13:15:40 +0000 Subject: [PATCH] Cleanup gcc warning bitset_t.c:39: warning: 'last' may be used uninitialized in this function Compiler is not smart enough to see the code path which avoid using unitialized 'last'. --- test/unit/bitset_t.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/bitset_t.c b/test/unit/bitset_t.c index ff6bbfd9a..b18ef94f4 100644 --- a/test/unit/bitset_t.c +++ b/test/unit/bitset_t.c @@ -36,7 +36,7 @@ int bitset_fini() { static void test_get_next() { - int i, j, last, first; + int i, j, last = 0, first; dm_bitset_t bs = dm_bitset_create(mem, NR_BITS); for (i = 0; i < NR_BITS; i++) -- 2.43.5