On Tue, 25 Oct 2011 18:13:11 +0200, Pascal Stumpf wrote: > Upstream fix is here. Attached are patches for devel/gdb, devel/libbfd > and base binutils 2.15 and 2.17 (permission to use under GPLv2 has been > granted, thanks to nickc at redhat dot com). > > > > Index: peXXigen.c > =================================================================== > RCS file: /cvs/src/gnu/usr.bin/binutils/bfd/peXXigen.c,v > retrieving revision 1.4 > diff -u -r1.4 peXXigen.c > --- peXXigen.c 2 Nov 2004 20:45:11 -0000 1.4 > +++ peXXigen.c 25 Oct 2011 14:16:35 -0000 > @@ -271,7 +271,7 @@ > in->x_file.x_n.x_offset = H_GET_32 (abfd, ext->x_file.x_n.x_offset); > } > else > - memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN); > + memcpy (in->x_file.x_fname, ext->x_file.x_fname, sizeof in->x_file.x_fn > ame); > return; > > case C_STAT: > @@ -344,7 +344,7 @@ > H_PUT_32 (abfd, in->x_file.x_n.x_offset, ext->x_file.x_n.x_offset); > } > else > - memcpy (ext->x_file.x_fname, in->x_file.x_fname, FILNMLEN); > + memcpy (ext->x_file.x_fname, in->x_file.x_fname, sizeof ext->x_file.x_f > name); > > return AUXESZ; > > Index: peXXigen.c > =================================================================== > RCS file: /cvs/src/gnu/usr.bin/binutils-2.17/bfd/peXXigen.c,v > retrieving revision 1.1.1.1 > diff -u -r1.1.1.1 peXXigen.c > --- peXXigen.c 24 Apr 2011 20:14:42 -0000 1.1.1.1 > +++ peXXigen.c 25 Oct 2011 14:17:23 -0000 > @@ -235,7 +235,7 @@ > in->x_file.x_n.x_offset = H_GET_32 (abfd, ext->x_file.x_n.x_offset); > } > else > - memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN); > + memcpy (in->x_file.x_fname, ext->x_file.x_fname, sizeof in->x_file.x_fn > ame); > return; > > case C_STAT: > @@ -308,7 +308,7 @@ > H_PUT_32 (abfd, in->x_file.x_n.x_offset, ext->x_file.x_n.x_offset); > } > else > - memcpy (ext->x_file.x_fname, in->x_file.x_fname, FILNMLEN); > + memcpy (ext->x_file.x_fname, in->x_file.x_fname, sizeof ext->x_file.x_f > name); > > return AUXESZ; > >
any OKs for these two?
