Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2011-12-10 05:33:56 +0400
committerChristopher Faylor <me@cgf.cx>2011-12-10 05:33:56 +0400
commitc1dedea603d4e9b281d8308070da53308f617f12 (patch)
tree386ed897f6beca520a2f737853889654be6f1ee3 /winsup/cygwin/exceptions.cc
parent83b25b0eb7c1ac69c4e431325df5f74d0a430caa (diff)
* exceptions.cc (ctrl_c_handler): YA in a series or reversions. Put back
_my_tls.remove along with a comment. (sigpacket::process): Remove code which now causes a gdb deadlock. * sigproc.cc (_cygtls::signal_exit): Signal debugger with signal number earlier.
Diffstat (limited to 'winsup/cygwin/exceptions.cc')
-rw-r--r--winsup/cygwin/exceptions.cc16
1 files changed, 7 insertions, 9 deletions
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc
index b16e8162a..351532a5e 100644
--- a/winsup/cygwin/exceptions.cc
+++ b/winsup/cygwin/exceptions.cc
@@ -936,6 +936,13 @@ ctrl_c_handler (DWORD type)
ExitProcess (STATUS_CONTROL_C_EXIT);
}
+ /* Remove early or we could overthrow the threadlist in cygheap.
+ Deleting this line causes ash to SEGV if CTRL-C is hit repeatedly.
+ I am not exactly sure why that is. Maybe it's just because this
+ adds some early serialization to ctrl_c_handler which prevents
+ multiple simultaneous calls? */
+ _my_tls.remove (INFINITE);
+
#if 0
if (type == CTRL_C_EVENT || type == CTRL_BREAK_EVENT)
proc_subproc (PROC_KILLFORKED, 0);
@@ -1235,15 +1242,6 @@ sigpacket::process ()
if (si.si_signo == SIGTSTP || si.si_signo == SIGTTIN || si.si_signo == SIGTTOU)
sig_clear (SIGCONT);
-#ifdef CGF
- if (being_debugged ())
- {
- char sigmsg[sizeof (_CYGWIN_SIGNAL_STRING " 0xffffffff")];
- __small_sprintf (sigmsg, _CYGWIN_SIGNAL_STRING " %p", si.si_signo);
- OutputDebugString (sigmsg);
- }
-#endif
-
if (handler == (void *) SIG_DFL)
{
if (insigwait_mask)