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]
Other format: [Raw text]

Re: Bug in pe_print_idata


Hi Laurent,

> I found a bug in pe_print_idata. In some PE files (namely drivers)
> the 'first thunk' is not located in the same section as the import
> table itself. This leads to weird behaviours, and segfaults.

Is there a simple way to reproduce this problem ?  Ideally I would
like a test that could be added to the test suite, but if this is not
feasible then some instructions on how to reproduce the failure would
be helpful.

> I attached a patch to fix the problem to this mail. It would be nice
> if someone with more binutils (especially bfd) knowledge than me
> could have a look at it

It looks reasonably OK to me, although I would suggest adding a
comment to explain why the search for the section containing the first
thunk is necessary.

> sure that I forgot something) and apply it.

Hmm, well normally we cannot accept submissions without a copyright
assignment, but in this case, since the patch is a reasonably small
bug fix I am prepared to accept it.  But I will definitely want some
way of testing it first.

Cheers
        Nick


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