summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/pulse/context.c6
-rw-r--r--src/pulsecore/core-util.c5
2 files changed, 11 insertions, 0 deletions
diff --git a/src/pulse/context.c b/src/pulse/context.c
index 5724765b..228053bc 100644
--- a/src/pulse/context.c
+++ b/src/pulse/context.c
@@ -132,6 +132,12 @@ pa_context *pa_context_new(pa_mainloop_api *mainloop, const char *name) {
memset(&c->spawn_api, 0, sizeof(c->spawn_api));
c->do_autospawn = 0;
+#ifndef MSG_NOSIGNAL
+#ifdef SIGPIPE
+ pa_check_signal_is_blocked(SIGPIPE);
+#endif
+#endif
+
c->conf = pa_client_conf_new();
pa_client_conf_load(c->conf, NULL);
#ifdef HAVE_X11
diff --git a/src/pulsecore/core-util.c b/src/pulsecore/core-util.c
index 16c3631f..7cb85209 100644
--- a/src/pulsecore/core-util.c
+++ b/src/pulsecore/core-util.c
@@ -78,6 +78,11 @@
#include "core-util.h"
+/* Not all platforms have this */
+#ifndef MSG_NOSIGNAL
+#define MSG_NOSIGNAL 0
+#endif
+
#ifndef OS_IS_WIN32
#define PA_RUNTIME_PATH_PREFIX "/tmp/pulse-"
#define PATH_SEP '/'