struct siginfo vs. siginfo_t

gdb/
	* amd64-linux-nat.c (amd64_linux_siginfo_fixup): Use siginfo_t instead
	of struct siginfo.
	* arm-linux-nat.c (arm_linux_stopped_data_address): Likewise.
	* ia64-linux-nat.c (ia64_linux_stopped_data_address): Likewise.
	* linux-nat.c (linux_nat_siginfo_fixup, siginfo_fixup)
	(linux_xfer_siginfo, linux_nat_set_siginfo_fixup)
	(linux_nat_get_siginfo): Likewise.
	* linux-nat.h (struct lwp_info, linux_nat_set_siginfo_fixup)
	(linux_nat_get_siginfo): Likewise.
	* linux-tdep.c (linux_get_siginfo_type): Likewise.
	* ppc-linux-nat.c (ppc_linux_stopped_data_address): Likewise.
	* procfs.c (gdb_siginfo_t): Likewise.

gdbserver/
	* linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
	struct siginfo.
	* linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
	* linux-x86-low.c (x86_siginfo_fixup): Likewise.
	* linux-low.h: Include <signal.h>.
	(struct siginfo): Remove forward declaration.
	(struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
	struct siginfo.
This commit is contained in:
Thomas Schwinge
2012-03-21 13:43:55 +00:00
parent 09c7a31ff5
commit a5362b9aa4
13 changed files with 53 additions and 28 deletions

View File

@ -4779,7 +4779,7 @@ linux_qxfer_osdata (const char *annex,
layout of the inferiors' architecture. */
static void
siginfo_fixup (struct siginfo *siginfo, void *inf_siginfo, int direction)
siginfo_fixup (siginfo_t *siginfo, void *inf_siginfo, int direction)
{
int done = 0;
@ -4791,9 +4791,9 @@ siginfo_fixup (struct siginfo *siginfo, void *inf_siginfo, int direction)
if (!done)
{
if (direction == 1)
memcpy (siginfo, inf_siginfo, sizeof (struct siginfo));
memcpy (siginfo, inf_siginfo, sizeof (siginfo_t));
else
memcpy (inf_siginfo, siginfo, sizeof (struct siginfo));
memcpy (inf_siginfo, siginfo, sizeof (siginfo_t));
}
}
@ -4802,8 +4802,8 @@ linux_xfer_siginfo (const char *annex, unsigned char *readbuf,
unsigned const char *writebuf, CORE_ADDR offset, int len)
{
int pid;
struct siginfo siginfo;
char inf_siginfo[sizeof (struct siginfo)];
siginfo_t siginfo;
char inf_siginfo[sizeof (siginfo_t)];
if (current_inferior == NULL)
return -1;