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:
authorDJ Delorie <dj@redhat.com>2007-11-01 01:22:31 +0300
committerDJ Delorie <dj@redhat.com>2007-11-01 01:22:31 +0300
commit69bfb481a875c4c79497a2dc34725f4e4a5ff175 (patch)
tree7a8c97b725e5ac4e1bf9a70f28924b08426ff6e0
parent6eedb2be6d441fc363dc63a70d23a9760be4d2ba (diff)
* libc/signal/signal.c (_raise_r): Don't attempt to initialize the
signal table, just use a default, in case initialization cause recursion.
-rw-r--r--newlib/ChangeLog6
-rw-r--r--newlib/libc/signal/signal.c9
2 files changed, 11 insertions, 4 deletions
diff --git a/newlib/ChangeLog b/newlib/ChangeLog
index f8609cb10..609e20999 100644
--- a/newlib/ChangeLog
+++ b/newlib/ChangeLog
@@ -1,3 +1,9 @@
+2007-10-31 DJ Delorie <dj@redhat.com>
+
+ * libc/signal/signal.c (_raise_r): Don't attempt to initialize the
+ signal table, just use a default, in case initialization cause
+ recursion.
+
2007-10-23 Jeff Johnston <jjohnstn@redhat.com>
* libc/stdlib/wcstombs_r.c: Add SUSV2 support for calculating
diff --git a/newlib/libc/signal/signal.c b/newlib/libc/signal/signal.c
index bfb85e66a..183004725 100644
--- a/newlib/libc/signal/signal.c
+++ b/newlib/libc/signal/signal.c
@@ -154,10 +154,11 @@ _DEFUN (_raise_r, (ptr, sig),
return -1;
}
- if (ptr->_sig_func == NULL && _init_signal_r (ptr) != 0)
- return -1;
-
- func = ptr->_sig_func[sig];
+ if (ptr->_sig_func == NULL)
+ func = SIG_DFL;
+ else
+ func = ptr->_sig_func[sig];
+
if (func == SIG_DFL)
return _kill_r (ptr, _getpid_r (ptr), sig);
else if (func == SIG_IGN)