readelf.c 'ext' may be used uninitialized
authorAlan Modra <amodra@gmail.com>
Tue, 19 Sep 2023 00:20:57 +0000 (09:50 +0930)
committerAlan Modra <amodra@gmail.com>
Tue, 19 Sep 2023 22:53:48 +0000 (08:23 +0930)
* readelf.c (display_lto_symtab): Init ext.

binutils/readelf.c

index 5c69efcbcd78e6632d03f065374af1da9c44271e..e9935c010cf892903e51c9707f8faa71b24e5a42 100644 (file)
@@ -13853,7 +13853,7 @@ display_lto_symtab (Filedata *           filedata,
     return false;
 
   /* Look for extended data for the symbol table.  */
-  Elf_Internal_Shdr * ext;
+  Elf_Internal_Shdr * ext = NULL;
   void * ext_data_orig = NULL;
   char * ext_data = NULL;
   char * ext_data_end = NULL;