RFA rs6000-nat.c rc used out of scope

Andrew Cagney ac131313@cygnus.com
Tue Apr 25 21:47:00 GMT 2000


Kevin Buettner wrote:
> 
> On Apr 25, 11:41am, Philippe De Muyter wrote:
> 
> > Building gdb on aix4.1.5 fails with :
> > gdb/rs6000-nat.c: In function `xcoff_relocate_symtab':
> > gdb/rs6000-nat.c:675: `rc' undeclared (first use this function)
> > gdb/rs6000-nat.c:675: (Each undeclared identifier is reported only once
> > gdb/rs6000-nat.c:675: for each function it appears in.)
> >
> > Here is a fix (using diff -b, to hide indent fixes)
> >
> > OK to commit ? (and do we really need an approval for such sort of things,
> > or would a FYI be enough ?)

> Your patch is fine, and I would normally approve it.  However, I see
> that the last person in this function (I won't name names) did not
> apply the patch that he said he would.  (I will bug him about it
> privately.)  Anyway, his proposed patch (which somehow didn't get
> applied) would fix the problem with rc being out of scope as well
> eliminate the use of alloca() from this function.
> 
> I'll leave it to Andrew to address your question regarding approval.
> (I'm curious about the answer myself.)

In theory this situtation doesn't arise.  The patches are always built /
tested before being committed.

In reality, life is a little more complex.  It isn't always possible to
test all cases.  However, I'd still like to try to stick with the theory
- and keep the maintainer in the loop - as far as possible.

Kevin, when he says ``However, I see ...'' probably illustrates why I
think this is generally better.  There are cases where the maintainer
does trip up badly but I think they are fairly rare.  If they prove to
be common then we've other problems.

If you want an example of where someone checking in a quick fix outside
of their domain can go wrong, have a look at my botched attempt at
fixing gdb/doc when it failed to build after more than a week.

	enjoy,
		Andrew


More information about the Gdb-patches mailing list