This is the mail archive of the gdb-patches@sourceware.org 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]

cancel: Re: [rfc 7/9]#2 Associate siginfo_t with any signal


Hi,

I have to think more about it, planning to still fix linux-nat.c when it got
written but without extending target_signal_t, making the siginfo just
internal to linux-nat.c simplifying it a lot at all.  It is just a legacy code
anyway before full switch to remote.c .


On Mon, 30 Aug 2010 21:11:43 +0200, Mark Kettenis wrote:
> > --- a/gdb/inf-ptrace.c
> > +++ b/gdb/inf-ptrace.c
> > +#ifndef PTRACE_GETSIGINFO
> > +# define PTRACE_GETSIGINFO	0x4202
> > +# define PTRACE_SETSIGINFO	0x4203
> > +#endif
> 
> Sorry, but this isn't right; it will make GDB perform random ioctls on
> non-Linux systems.
> 
> Instead the siginfo support code in this file should be wrapped in
> #ifdef PTRACE_GETSIGINFO.  Sorry, Linux users just have to make sure
> their header files match the kernel they're running.

In general I do not agree with these defines at all, I have just copied the
existing code/style.  It is normal the #defines in headers get fixed for
during OS release.  Also it would be weird if linux-nat.c was using
PTRACE_GETSIGINFO/PTRACE_SETSIGINFO while called inf-ptrace.c would not be
using it.


Thanks,
Jan


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