bfd/
authorTristan Gingold <gingold@adacore.com>
Thu, 2 Feb 2012 11:55:43 +0000 (11:55 +0000)
committerTristan Gingold <gingold@adacore.com>
Thu, 2 Feb 2012 11:55:43 +0000 (11:55 +0000)
2012-02-02  Tristan Gingold  <gingold@adacore.com>

* mach-o.c (bfd_mach_o_read_header): Silent uninitialized
variable warning.

gas/
2012-02-02  Tristan Gingold  <gingold@adacore.com>

* config/obj-macho.c (obj_mach_o_zerofill): Silent
uninitialized variable warning.

bfd/ChangeLog
bfd/mach-o.c
gas/ChangeLog
gas/config/obj-macho.c

index ad85fca..5efae57 100644 (file)
@@ -1,5 +1,10 @@
 2012-02-02  Tristan Gingold  <gingold@adacore.com>
 
+       * mach-o.c (bfd_mach_o_read_header): Silent uninitialized
+       variable warning.
+
+2012-02-02  Tristan Gingold  <gingold@adacore.com>
+
        * archive.c (bfd_slurp_armap): Fix thinko in cast.
 
 2012-01-31  H.J. Lu  <hongjiu.lu@intel.com>
index a13ac4e..5386b1a 100644 (file)
@@ -2522,6 +2522,8 @@ bfd_mach_o_read_header (bfd *abfd, bfd_mach_o_header *header)
 
   if (mach_o_wide_p (header))
     header->reserved = (*get32) (raw.reserved);
+  else
+    header->reserved = 0;
 
   return TRUE;
 }
index f37e6b0..143667a 100644 (file)
@@ -1,3 +1,8 @@
+2012-02-02  Tristan Gingold  <gingold@adacore.com>
+
+       * config/obj-macho.c (obj_mach_o_zerofill): Silent
+       uninitialized variable warning.
+
 2012-02-02  Nick Clifton  <nickc@redhat.com>
 
        PR gas/13224
index f0cb43e..f4706ab 100644 (file)
@@ -434,7 +434,7 @@ obj_mach_o_zerofill (int ignore ATTRIBUTE_UNUSED)
   symbolS *sym = NULL;
   unsigned int align = 0;
   unsigned int specified_mask = 0;
-  offsetT size;
+  offsetT size = 0;
 
 #ifdef md_flush_pending_output
   md_flush_pending_output ();