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>2012-12-08 00:59:44 +0400
committerChristopher Faylor <me@cgf.cx>2012-12-08 00:59:44 +0400
commitff8ba3cabe838db3f354b1d04f4b30abdf17df2c (patch)
treea9216ab9cf41a629138614a5582f102afd58cd2c /winsup/cygwin/exceptions.cc
parent0d1a50b81ab8e79642bfd17b019f3eb0a17073c6 (diff)
* exceptions.cc (sigpacket::process): Reorganize to avoid use of tls before
initialization. * fhandler_fifo.cc (fhandler_fifo::arm): Avoid improper printing of integer as a string in debug output.
Diffstat (limited to 'winsup/cygwin/exceptions.cc')
-rw-r--r--winsup/cygwin/exceptions.cc24
1 files changed, 12 insertions, 12 deletions
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc
index a28b90af5..590fcd9b5 100644
--- a/winsup/cygwin/exceptions.cc
+++ b/winsup/cygwin/exceptions.cc
@@ -1123,7 +1123,6 @@ sigpacket::process ()
{
bool continue_now;
struct sigaction dummy = global_sigs[SIGSTOP];
- _cygtls *tls;
if (si.si_signo != SIGCONT)
continue_now = false;
@@ -1159,20 +1158,11 @@ sigpacket::process ()
myself->rusage_self.ru_nsignals++;
- void *handler = (void *) thissig.sa_handler;
- if (handler == SIG_IGN)
- {
- sigproc_printf ("signal %d ignored", si.si_signo);
- goto done;
- }
-
- if (have_execed)
- handler = NULL;
-
+ _cygtls *tls;
if (sigtls)
{
tls = sigtls;
- sigproc_printf ("using sigtls %p", tls);
+ sigproc_printf ("using sigtls %p", sigtls);
}
else
{
@@ -1180,6 +1170,16 @@ sigpacket::process ()
sigproc_printf ("using tls %p", tls);
}
+ void *handler = (void *) thissig.sa_handler;
+ if (have_execed)
+ handler = NULL;
+
+ if (handler == SIG_IGN)
+ {
+ sigproc_printf ("signal %d ignored", si.si_signo);
+ goto done;
+ }
+
if (si.si_signo == SIGKILL)
goto exit_sig;
if (si.si_signo == SIGSTOP)