Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [linux] Always ignore restart/cancellation signals
@ 2005-12-08 21:10 Daniel Jacobowitz
  2005-12-09 10:39 ` Mark Kettenis
  2006-02-20 17:01 ` Daniel Jacobowitz
  0 siblings, 2 replies; 19+ messages in thread
From: Daniel Jacobowitz @ 2005-12-08 21:10 UTC (permalink / raw)
  To: gdb-patches

The comment is fairly self-explanatory.  I guess I've always debugged
failing cancellation tests with gdbserver, which hardwires these values
already...

Any objections?

-- 
Daniel Jacobowitz
CodeSourcery, LLC

2005-12-07  Daniel Jacobowitz  <dan@codesourcery.com>

	* linux-nat.c (lin_thread_get_thread_signals): Default to __SIGRTMIN
	and __SIGRTMIN + 1.

Index: gdb-6.4/gdb/linux-nat.c
===================================================================
--- gdb-6.4.orig/gdb/linux-nat.c	2005-11-03 14:51:40.000000000 -0500
+++ gdb-6.4/gdb/linux-nat.c	2005-12-07 21:44:12.000000000 -0500
@@ -3284,12 +3284,18 @@ lin_thread_get_thread_signals (sigset_t 
   sigemptyset (set);
 
   restart = get_signo ("__pthread_sig_restart");
+  cancel = get_signo ("__pthread_sig_cancel");
+
+  /* LinuxThreads normally uses the first two RT signals, but in some legacy
+     cases may use SIGUSR1/SIGUSR2.  NPTL always uses RT signals, but does
+     not provide any way for the debugger to query the signal numbers -
+     fortunately they don't change!  */
+
   if (restart == 0)
-    return;
+    restart = __SIGRTMIN;
 
-  cancel = get_signo ("__pthread_sig_cancel");
   if (cancel == 0)
-    return;
+    cancel = __SIGRTMIN + 1;
 
   sigaddset (set, restart);
   sigaddset (set, cancel);


^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2006-02-20 17:01 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-08 21:10 [linux] Always ignore restart/cancellation signals Daniel Jacobowitz
2005-12-09 10:39 ` Mark Kettenis
2005-12-09 11:09   ` Kevin Buettner
2005-12-09 11:26     ` Daniel Jacobowitz
2005-12-09 11:48       ` Kevin Buettner
2005-12-09 14:46       ` Eli Zaretskii
2005-12-09 20:52         ` Daniel Jacobowitz
2005-12-09 20:49           ` Daniel Jacobowitz
2005-12-09 21:55           ` Eli Zaretskii
2005-12-09 23:13             ` Daniel Jacobowitz
2005-12-10  1:20               ` Eli Zaretskii
2005-12-10  1:29                 ` Daniel Jacobowitz
2005-12-10  1:29                   ` Eli Zaretskii
2005-12-10  1:49                   ` Mark Kettenis
2005-12-10  2:10                     ` Daniel Jacobowitz
2005-12-10  4:47                       ` Mark Kettenis
2005-12-10  1:34         ` Jim Blandy
2005-12-11 17:26           ` Eli Zaretskii
2006-02-20 17:01 ` Daniel Jacobowitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox