From: Hans-Peter Nilsson Date: Thu, 14 Sep 2017 02:52:20 +0000 (+0200) Subject: * dwarf.c (display_debug_names): Initialize hash_prev. X-Git-Tag: binutils-2_29_1~6 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ab0462915cae36d5af2315540745f348603ad61f;p=thirdparty%2Fbinutils-gdb.git * dwarf.c (display_debug_names): Initialize hash_prev. gcc-4.3.0 warns that it may be used uninitialized. It takes a look and a half at the code to understand that it's false. Import from mainline. --- diff --git a/binutils/ChangeLog b/binutils/ChangeLog index cffc49a66ea..1df592163eb 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,8 @@ +2017-07-18 Hans-Peter Nilsson + + Import from mainline: + * dwarf.c (display_debug_names): Initialize hash_prev. + 2017-09-05 Nick Clifton Import from mainline: diff --git a/binutils/dwarf.c b/binutils/dwarf.c index 419839b581e..3842ffdf118 100644 --- a/binutils/dwarf.c +++ b/binutils/dwarf.c @@ -7816,7 +7816,7 @@ display_debug_names (struct dwarf_section *section, void *file) printf (_("Used %zu of %lu buckets.\n"), buckets_filled, (unsigned long) bucket_count); - uint32_t hash_prev; + uint32_t hash_prev = 0; size_t hash_clash_count = 0; size_t longest_clash = 0; size_t this_length = 0;