]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE14-netbsd-sigwait-broken-til-nbsd5-20080816
authorTracy Di Marco White <gendalia@iastate.edu>
Sat, 16 Aug 2008 20:47:10 +0000 (20:47 +0000)
committerDerrick Brashear <shadow@dementia.org>
Sat, 16 Aug 2008 20:47:10 +0000 (20:47 +0000)
LICENSE IPL10
FIXES 111404

work around netbsd sigwait brokenness

(cherry picked from commit 8190e75b38a7cd136ce70050fdd71b1d62888055)

src/util/softsig.c

index c88ca20a7e05458312e7416eb771773e2710ded3..33981b870e6fe5a23f2791f025139967b1264da3 100644 (file)
@@ -37,7 +37,7 @@ static pthread_t softsig_tid;
 static struct {
     void (*handler) (int);
     int pending;
-#if !(defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD30_ENV)))
+#if !(defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD50_ENV)))
     int fatal;
 #endif /* !defined(AFS_DARWIN60_ENV) || !defined(AFS_NBSD_ENV) */
     int inited;
@@ -54,7 +54,7 @@ softsig_thread(void *arg)
     pthread_sigmask(SIG_BLOCK, &ss, &os);
     pthread_sigmask(SIG_SETMASK, &os, NULL);
     sigaddset(&ss, SIGUSR1);
-#if defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD30_ENV))
+#if defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD50_ENV))
     pthread_sigmask (SIG_BLOCK, &ss, NULL);
     sigdelset (&os, SIGUSR1);
 #else /* !defined(AFS_DARWIN60_ENV) && !defined(AFS_NBSD_ENV) */
@@ -75,7 +75,7 @@ softsig_thread(void *arg)
        for (i = 0; i < NSIG; i++) {
            if (softsig_sigs[i].handler && !softsig_sigs[i].inited) {
                sigaddset(&ss, i);
-#if defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD30_ENV))
+#if defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD50_ENV))
                pthread_sigmask (SIG_BLOCK, &ss, NULL);
                sigdelset (&os, i);
 #endif /* defined(AFS_DARWIN60_ENV) || defined(AFS_NBSD_ENV) */
@@ -88,7 +88,7 @@ softsig_thread(void *arg)
            }
        }
        if (i == NSIG) {
-#if defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD30_ENV))
+#if defined(AFS_DARWIN60_ENV) || (defined(AFS_NBSD_ENV) && !defined(AFS_NBSD50_ENV))
            sigsuspend (&os);
 #else /* !defined(AFS_DARWIN60_ENV) && !defined(AFS_NBSD_ENV) */
            sigwait(&ss, &sigw);