summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Steves <stevesk@pobox.com>2001-02-18 03:42:02 +0000
committerKevin Steves <stevesk@pobox.com>2001-02-18 03:42:02 +0000
commiteff26f275eca8fb4c1dab03599ad21d79a8a55ea (patch)
tree3e410ef0884356847f5f3161ca8a2e47ef8deabb
parentdf28802cddeb887a6fa3c4a8e8a4f208ce3652b5 (diff)
- (stevesk) misc.c: cpp rework of SA_(INTERRUPT|RESTART) handling.
-rw-r--r--ChangeLog3
-rw-r--r--misc.c8
2 files changed, 6 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 4c31db9c..f2db25bb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -19,6 +19,7 @@
SunOS)
- (djm) SCO needs librpc for libwrap. Patch from Tim Rice
<tim@multitalents.net>
+ - (stevesk) misc.c: cpp rework of SA_(INTERRUPT|RESTART) handling.
20010217
- (bal) OpenBSD Sync:
@@ -4026,4 +4027,4 @@
- Wrote replacements for strlcpy and mkdtemp
- Released 1.0pre1
-$Id: ChangeLog,v 1.792 2001/02/18 02:09:40 djm Exp $
+$Id: ChangeLog,v 1.793 2001/02/18 03:42:02 stevesk Exp $
diff --git a/misc.c b/misc.c
index 4ec5d55f..6ce66fc4 100644
--- a/misc.c
+++ b/misc.c
@@ -108,13 +108,13 @@ mysignal(int sig, mysig_t act)
memset(&sa, 0, sizeof(sa));
sigemptyset(&sa.sa_mask);
sa.sa_flags = 0;
-#ifdef SA_RESTART
if (sig == SIGCHLD)
+#if defined(SA_RESTART)
sa.sa_flags |= SA_RESTART;
-#endif
-#ifdef SA_INTERRUPT
- if (sig == SIGCHLD)
+#elif defined(SA_INTERRUPT)
sa.sa_flags |= SA_INTERRUPT;
+#else
+ ;
#endif
sa.sa_handler = act;
if (sigaction(sig, &sa, NULL) == -1)