[patch] remove bogus "struct sigaction"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Wichert,

Somebody made their own "struct new_sigaction".  God knows why.

It should be #ifdef'd if it's actually useful to someone (right?),
but it's incompatible with linux-mips.  My patch... using the
struct sigaction out of the standard #includes... Works For Me TM.

Cheers,
Andrew


diff -rpu strace-4.4/signal.c strace-4.4-fixed/signal.c
--- strace-4.4/signal.c	Sun Aug 19 22:06:50 2001
+++ strace-4.4-fixed/signal.c	Thu Jan 23 23:30:59 2003
@@ -1363,26 +1363,11 @@ typedef struct siginfo
 } siginfo_t;
 #endif
 
-/* Structure describing the action to be taken when a signal arrives.  */
-struct new_sigaction
-{
-	union
-	{
-		__sighandler_t __sa_handler;
-		void (*__sa_sigaction) (int, siginfo_t *, void *);
-	}
-	__sigaction_handler;
-	unsigned long sa_flags;
-	void (*sa_restorer) (void);
-	unsigned long int sa_mask[2];
-};
-
-
 	int
 sys_rt_sigaction(tcp)
 	struct tcb *tcp;
 {
-	struct new_sigaction sa;
+	struct sigaction sa;
 	sigset_t sigset;
 	long addr;
 
@@ -1399,7 +1384,7 @@ sys_rt_sigaction(tcp)
 	else if (umove(tcp, addr, &sa) < 0)
 		tprintf("{...}");
 	else {
-		switch ((long) sa.__sigaction_handler.__sa_handler) {
+		switch ((long) sa.sa_handler) {
 			case (long) SIG_ERR:
 				tprintf("{SIG_ERR}");
 				break;
@@ -1410,8 +1395,7 @@ sys_rt_sigaction(tcp)
 				tprintf("{SIG_IGN}");
 				break;
 			default:
-				tprintf("{%#lx, ",
-						(long) sa.__sigaction_handler.__sa_handler);
+				tprintf("{%#lx, ", (long) sa.sa_handler);
 				sigemptyset(&sigset);
 #ifdef LINUXSPARC
 				if (tcp->u_arg[4] <= sizeof(sigset))



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux