This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB 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: PATCH: MinGW readline -- revised


On Mon, Jul 18, 2005 at 05:11:01PM -0700, Mark Mitchell wrote:
> 
> This patch is the revised GDB-on-MinGW bit.
> 
> There are three subparts:

Unfortunately, this is a good example of why unrelated fixes
shouldn't be combined...

> 1) Minor bit-rot in remote-sim.c and ser-tcp.c on MinGW.  In
>    particular, SIGTRAP is being used unconditionally in the former,
>    and the MinGW definition of "close" (in terms of "closesocket")
>    needs to be a function-like macro, so as to avoid confusion in
>    code like "ops->close = net_close".

I'm not sure why you call this "bit-rot".

The unconditional use of SIGTRAP has been there since the oldest
version of GDB in CVS.  Paul posted a patch to provide a default
definition of SIGTRAP instead in two places; his patch is more correct
than yours, and is on the csl-arm branch.  See the simulator sources to
understand why you can't just ignore SIGTRAP here; the simulator will
be completely broken by this change.  Paul's approach is still somewhat
incorrect, in that there is no valid excuse for using native signal
numbers here.  The simulators really need to be fixed, but it would be
a Herculean effort.  I am inclined to go with Paul's patch for the
nonce.

Similarly the reference to ops->close is from 2002.

> 2) On the GDB side, I've added a win32-termcap.c file that contains
>    the stub termcap implementation.  There seemed to be no consensus
>    that it belongs in libiberty, so I've submitted it here.  I'd
>    really appreciate being able to check this in; if it's later
>    decided that it's wanted in libiberty, I'll happily move it.
> 
> 3) On the readline side, I've backported the MinGW changes that will
>    be in readline 5.1.

These look fine; the changes aren't quite the way I'd have liked them,
but if they've been taken for readline 5.1, it's important that we
minimize divergence.  Chris, do these parts look OK to you?

-- 
Daniel Jacobowitz
CodeSourcery, LLC


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