]> code.delx.au - pulseaudio/commitdiff
libpulse: Cope with systems not implementing SA_NOCLDWAIT
authorPino Toscano <pino@debian.org>
Mon, 19 Mar 2012 12:42:15 +0000 (12:42 +0000)
committerArun Raghavan <arun.raghavan@collabora.co.uk>
Wed, 28 Mar 2012 10:53:52 +0000 (16:23 +0530)
Even though SA_NOCLDWAIT is a POSIX mandatory flag the Hurd doesn't
implement it. So let's only check for it if it's defined.

src/pulse/context.c

index e03d88ca8d887bd1aaabf79fa4fb35344624b125..5bd3448b04039e14c12e334f0e763c449a692b90 100644 (file)
@@ -660,7 +660,11 @@ static int context_autospawn(pa_context *c) {
         goto fail;
     }
 
+#ifdef SA_NOCLDWAIT
     if ((sa.sa_flags & SA_NOCLDWAIT) || sa.sa_handler == SIG_IGN) {
+#else
+    if (sa.sa_handler == SIG_IGN) {
+#endif
         pa_log_debug("Process disabled waitpid(), cannot autospawn.");
         pa_context_fail(c, PA_ERR_CONNECTIONREFUSED);
         goto fail;