This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Fix for bfd/dwarf1.c


Will Cohen wrote:
> 
> Alan Modra wrote:
> >
> > On Tue, 3 Oct 2000, Will Cohen wrote:
> >
> > > 2000-10-03  Will Cohen  <wcohen@redhat.com>
> > >
> > >       * dwarf1.c (_bfd_dwarf1_find_nearest_line): Added code to
> > >       initialize fields in aUnit.
> > >
> > > This fixes a problem with some unitialized pointer fields being
> > > filled with garbage, causing the linker to crash on winNT
> > > when trying to link code with debugging information.
> >
> > But "aUnit" is allocated using bfd_zalloc, so I don't see what your patch
> > is doing.  The fields you are zeroing should already be zero from the
> > bfd_zalloc.
> >
> > Alan Modra
> > --
> > Linuxcare.  Support for the Revolution.
> 
> Those field were not being zeroed as expected on winNT.
> I will take another look.
> 
> -Will

I was looking at an older version of binutils.  The code in dwarf1.c
was the same.  The older version does not zero out the array.  There
have been changes between this older version and the newer version
in opncls.c.  The newer version zeros out each array.  Thus, there
is no need for the patch I suggested for the newer version of binutils.

-Will

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]