On Fri, Sep 14, 2012 at 01:40:59PM -0700, Roland McGrath wrote:
> > > mips_debugscn_p (const GElf_Shdr *shdr, const char
*name)
> > > {
> > > if (shdr != NULL && shdr->sh_type == SHT_MIPS_DWARF)
> > > return true;
> > > return (*generic_debugscn_p) (shdr, name);
> > > }
> >
> > Does that mean generic_debugscn shouldn't check the shdr? Because
> > now it would check it and then fail for mips because it's not
> > SHT_PROGBITS.
The code above never calls generic_debugscn if sh_type is SHT_MIPS_DWARF.
If the type is neither SHT_MIPS_DWARF nor SHT_PROGBITS, I don't know why
we'd want it to return true. I don't understand what case you are
concerned about.
Re-reading the code I don't understand either.
Kurt