5cfc5a9
diff -rup binutils.orig/gold/gdb-index.cc binutils-2.34.0/gold/gdb-index.cc
5cfc5a9
--- binutils.orig/gold/gdb-index.cc	2020-07-24 09:12:29.241306445 +0100
5cfc5a9
+++ binutils-2.34.0/gold/gdb-index.cc	2020-07-24 09:15:48.332095898 +0100
5cfc5a9
@@ -817,7 +817,7 @@ Gdb_index_info_reader::get_qualified_nam
5cfc5a9
 void
5cfc5a9
 Gdb_index_info_reader::record_cu_ranges(Dwarf_die* die)
5cfc5a9
 {
5cfc5a9
-  unsigned int shndx;
5cfc5a9
+  unsigned int shndx = 0;
5cfc5a9
   unsigned int shndx2;
5cfc5a9
 
5cfc5a9
   off_t ranges_offset = die->ref_attribute(elfcpp::DW_AT_ranges, &shndx);
5cfc5a9
diff -rup binutils.orig/gold/layout.cc binutils-2.34.0/gold/layout.cc
5cfc5a9
--- binutils.orig/gold/layout.cc	2020-07-24 09:12:29.243306433 +0100
5cfc5a9
+++ binutils-2.34.0/gold/layout.cc	2020-07-24 09:15:11.464320064 +0100
5cfc5a9
@@ -1986,7 +1986,7 @@ Layout::attach_allocated_section_to_segm
5cfc5a9
   seg_flags |= os->extra_segment_flags();
5cfc5a9
 
5cfc5a9
   // Check for --section-start.
5cfc5a9
-  uint64_t addr;
5cfc5a9
+  uint64_t addr = 0;
5cfc5a9
   bool is_address_set = parameters->options().section_start(os->name(), &addr);
5cfc5a9
 
5cfc5a9
   // In general the only thing we really care about for PT_LOAD
5cfc5a9
diff -rup binutils.orig/binutils/dlltool.c binutils-2.34.0/binutils/dlltool.c
5cfc5a9
--- binutils.orig/binutils/dlltool.c	2020-07-24 09:12:28.974308069 +0100
5cfc5a9
+++ binutils-2.34.0/binutils/dlltool.c	2020-07-24 12:09:37.527121295 +0100
5cfc5a9
@@ -1305,7 +1305,7 @@ run (const char *what, char *args)
5cfc5a9
   int pid, wait_status;
5cfc5a9
   int i;
5cfc5a9
   const char **argv;
5cfc5a9
-  char *errmsg_fmt, *errmsg_arg;
5cfc5a9
+  char *errmsg_fmt = "", *errmsg_arg = "";
5cfc5a9
   char *temp_base = choose_temp_base ();
5cfc5a9
 
5cfc5a9
   inform (_("run: %s %s"), what, args);
5cfc5a9
diff -rup binutils.orig/gas/config/tc-arm.c binutils-2.34.0/gas/config/tc-arm.c
5cfc5a9
--- binutils.orig/gas/config/tc-arm.c	2020-07-24 09:12:32.368287432 +0100
5cfc5a9
+++ binutils-2.34.0/gas/config/tc-arm.c	2020-07-24 12:14:19.842360634 +0100
5cfc5a9
@@ -28416,9 +28416,12 @@ md_apply_fix (fixS *	fixP,
5cfc5a9
 	 perform relaxation.  */
5cfc5a9
       if (value == -2)
5cfc5a9
 	{
5cfc5a9
-	  newval = md_chars_to_number (buf, THUMB_SIZE);
5cfc5a9
-	  newval = 0xbf00; /* NOP encoding T1 */
5cfc5a9
-	  md_number_to_chars (buf, newval, THUMB_SIZE);
5cfc5a9
+	  if (fixP->fx_done || !seg->use_rela_p)
5cfc5a9
+	    {
5cfc5a9
+	      newval = md_chars_to_number (buf, THUMB_SIZE);
5cfc5a9
+	      newval = 0xbf00; /* NOP encoding T1 */
5cfc5a9
+	      md_number_to_chars (buf, newval, THUMB_SIZE);
5cfc5a9
+	    }
5cfc5a9
 	}
5cfc5a9
       else
5cfc5a9
 	{
5cfc5a9
@@ -28631,17 +28634,14 @@ md_apply_fix (fixS *	fixP,
5cfc5a9
     case BFD_RELOC_ARM_GOTFUNCDESC:
5cfc5a9
     case BFD_RELOC_ARM_GOTOFFFUNCDESC:
5cfc5a9
     case BFD_RELOC_ARM_FUNCDESC:
5cfc5a9
-      if (arm_fdpic)
5cfc5a9
-	{
5cfc5a9
-	  if (fixP->fx_done || !seg->use_rela_p)
5cfc5a9
-	    md_number_to_chars (buf, 0, 4);
5cfc5a9
-	}
5cfc5a9
-      else
5cfc5a9
+      if (!arm_fdpic)
5cfc5a9
 	{
5cfc5a9
 	  as_bad_where (fixP->fx_file, fixP->fx_line,
5cfc5a9
 			_("Relocation supported only in FDPIC mode"));
5cfc5a9
-      }
5cfc5a9
-      break;
5cfc5a9
+	  break;
5cfc5a9
+	}
5cfc5a9
+      value = 0;
5cfc5a9
+      /* Fall through.  */
5cfc5a9
 #endif
5cfc5a9
 
5cfc5a9
     case BFD_RELOC_RVA:
5cfc5a9
diff -rup binutils.orig/gas/config/tc-arm.c binutils-2.34.0/gas/config/tc-arm.c
5cfc5a9
--- binutils.orig/gas/config/tc-arm.c	2020-07-24 12:16:02.099719884 +0100
5cfc5a9
+++ binutils-2.34.0/gas/config/tc-arm.c	2020-07-24 12:34:17.690858328 +0100
5cfc5a9
@@ -28641,7 +28641,7 @@ md_apply_fix (fixS *	fixP,
5cfc5a9
 	  break;
5cfc5a9
 	}
5cfc5a9
       value = 0;
5cfc5a9
-      /* Fall through.  */
5cfc5a9
+      goto fred;
5cfc5a9
 #endif
5cfc5a9
 
5cfc5a9
     case BFD_RELOC_RVA:
5cfc5a9
@@ -28653,6 +28653,7 @@ md_apply_fix (fixS *	fixP,
5cfc5a9
 #ifdef TE_PE
5cfc5a9
     case BFD_RELOC_32_SECREL:
5cfc5a9
 #endif
5cfc5a9
+    fred:
5cfc5a9
       if (fixP->fx_done || !seg->use_rela_p)
5cfc5a9
 #ifdef TE_WINCE
5cfc5a9
 	/* For WinCE we only do this for pcrel fixups.  */
5cfc5a9
diff -rup binutils.orig/gas/config/tc-arm.c binutils-2.34.0/gas/config/tc-arm.c
5cfc5a9
--- binutils.orig/gas/config/tc-arm.c	2020-07-24 13:28:26.926553452 +0100
5cfc5a9
+++ binutils-2.34.0/gas/config/tc-arm.c	2020-07-24 13:31:57.835215763 +0100
5cfc5a9
@@ -28416,12 +28416,8 @@ md_apply_fix (fixS *	fixP,
5cfc5a9
 	 perform relaxation.  */
5cfc5a9
       if (value == -2)
5cfc5a9
 	{
5cfc5a9
-	  if (fixP->fx_done || !seg->use_rela_p)
5cfc5a9
-	    {
5cfc5a9
-	      newval = md_chars_to_number (buf, THUMB_SIZE);
5cfc5a9
-	      newval = 0xbf00; /* NOP encoding T1 */
5cfc5a9
-	      md_number_to_chars (buf, newval, THUMB_SIZE);
5cfc5a9
-	    }
5cfc5a9
+	  newval = 0xbf00; /* NOP encoding T1 */
5cfc5a9
+	  goto jim;
5cfc5a9
 	}
5cfc5a9
       else
5cfc5a9
 	{
5cfc5a9
@@ -28432,6 +28428,7 @@ md_apply_fix (fixS *	fixP,
5cfc5a9
 	    {
5cfc5a9
 	      newval = md_chars_to_number (buf, THUMB_SIZE);
5cfc5a9
 	      newval |= ((value & 0x3e) << 2) | ((value & 0x40) << 3);
5cfc5a9
+	    jim:
5cfc5a9
 	      md_number_to_chars (buf, newval, THUMB_SIZE);
5cfc5a9
 	    }
5cfc5a9
 	}
5cfc5a9
diff -rup binutils.orig/binutils/mclex.c binutils-2.34.0/binutils/mclex.c
5cfc5a9
--- binutils.orig/binutils/mclex.c	2020-07-24 13:28:26.297557441 +0100
5cfc5a9
+++ binutils-2.34.0/binutils/mclex.c	2020-07-24 14:46:53.587940149 +0100
5cfc5a9
@@ -207,7 +207,7 @@ enum_severity (int e)
5cfc5a9
 static void
5cfc5a9
 mc_add_keyword_ascii (const char *sz, int rid, const char *grp, rc_uint_type nv, const char *sv)
5cfc5a9
 {
5cfc5a9
-  unichar *usz, *usv = NULL;
5cfc5a9
+  unichar *usz = NULL, *usv = NULL;
5cfc5a9
   rc_uint_type usz_len;
5cfc5a9
 
5cfc5a9
   unicode_from_codepage (&usz_len, &usz, sz, CP_ACP);
5cfc5a9
diff -rup binutils.orig/binutils/windmc.c binutils-2.34.0/binutils/windmc.c
5cfc5a9
--- binutils.orig/binutils/windmc.c	2020-07-24 13:28:26.279557556 +0100
5cfc5a9
+++ binutils-2.34.0/binutils/windmc.c	2020-07-24 14:48:05.460477478 +0100
5cfc5a9
@@ -338,7 +338,7 @@ mc_add_node_lang (mc_node *root, const m
5cfc5a9
 static char *
5cfc5a9
 convert_unicode_to_ACP (const unichar *usz)
5cfc5a9
 {
5cfc5a9
-  char *s;
5cfc5a9
+  char *s = NULL;
5cfc5a9
   rc_uint_type l;
5cfc5a9
 
5cfc5a9
   if (! usz)
5cfc5a9
@@ -607,10 +607,10 @@ mc_generate_bin_item (mc_node_lang *n, r
5cfc5a9
   else
5cfc5a9
     {
5cfc5a9
       rc_uint_type txt_len, l;
5cfc5a9
-      char *cvt_txt;
5cfc5a9
+      char *cvt_txt = NULL;
5cfc5a9
 
5cfc5a9
       codepage_from_unicode( &l, n->message, &cvt_txt, n->lang->lang_info.wincp);
5cfc5a9
-      if (! cvt_txt)
5cfc5a9
+      if (cvt_txt == NULL)
5cfc5a9
 	fatal ("Failed to convert message to language codepage.\n");
5cfc5a9
       txt_len = strlen (cvt_txt);
5cfc5a9
       if (mcset_automatic_null_termination && txt_len > 0)
5cfc5a9
@@ -1107,7 +1107,7 @@ main (int argc, char **argv)
5cfc5a9
 
5cfc5a9
   /* Load the input file and do code page transformations to UTF16.  */
5cfc5a9
   {
5cfc5a9
-    unichar *u;
5cfc5a9
+    unichar *u = NULL;
5cfc5a9
     rc_uint_type ul;
5cfc5a9
     char *buff;
5cfc5a9
     bfd_size_type flen;
5cfc5a9
--- binutils.orig/binutils/srconv.c	2020-07-24 15:37:25.847459208 +0100
5cfc5a9
+++ binutils-2.34.0/binutils/srconv.c	2020-07-24 15:39:12.853773423 +0100
5cfc5a9
@@ -316,6 +316,7 @@ wr_hd (struct coff_ofile *p)
5cfc5a9
   struct IT_hd hd;
5cfc5a9
 
5cfc5a9
   hd.spare1 = 0;
5cfc5a9
+  hd.spare2 = 0;
5cfc5a9
   if (bfd_get_file_flags (abfd) & EXEC_P)
5cfc5a9
     hd.mt = MTYPE_ABS_LM;
5cfc5a9
   else