all: avoid bogus compiler warning about uninitialized variable

With LTO and optimizations, gcc issues several bogus
"maybe-uninitialized" warnings.

Work-around them by initializing the variables.
This commit is contained in:
Thomas Haller
2019-02-03 11:15:11 +01:00
committed by Beniamino Galvani
parent 14957e914a
commit c77871e5e9
5 changed files with 10 additions and 6 deletions

View File

@@ -890,7 +890,8 @@ void internal_hashmap_clear(HashmapBase *h, free_func_t default_free_key, free_f
* themselves from our hash table a second time, the entry is already gone. */
while (internal_hashmap_size(h) > 0) {
void *v, *k;
void *k = NULL;
void *v;
v = internal_hashmap_first_key_and_value(h, true, &k);