+2011-12-12 Iain Sandoe <iains@gcc.gnu.org>
+
+ * mach-o.c (bfd_mach_o_read_section_32): Null-terminate sectname.
+ (bfd_mach_o_read_section_64): Likewise.
+
2011-12-11 John Davis Anglin <dave.anglin@nrc-cnrc.gc.ca>
PR binutils/13476
memcpy (section->segname, raw.segname, sizeof (raw.segname));
section->segname[BFD_MACH_O_SEGNAME_SIZE] = 0;
memcpy (section->sectname, raw.sectname, sizeof (raw.sectname));
- section->segname[BFD_MACH_O_SECTNAME_SIZE] = 0;
+ section->sectname[BFD_MACH_O_SECTNAME_SIZE] = 0;
section->addr = bfd_h_get_32 (abfd, raw.addr);
section->size = bfd_h_get_32 (abfd, raw.size);
section->offset = bfd_h_get_32 (abfd, raw.offset);
memcpy (section->segname, raw.segname, sizeof (raw.segname));
section->segname[BFD_MACH_O_SEGNAME_SIZE] = 0;
memcpy (section->sectname, raw.sectname, sizeof (raw.sectname));
- section->segname[BFD_MACH_O_SECTNAME_SIZE] = 0;
+ section->sectname[BFD_MACH_O_SECTNAME_SIZE] = 0;
section->addr = bfd_h_get_64 (abfd, raw.addr);
section->size = bfd_h_get_64 (abfd, raw.size);
section->offset = bfd_h_get_32 (abfd, raw.offset);