Hi,

This patch is in use in Debian for some time.
Please consider accepting it to the project's codebase.

Thanks,
Balint
From 817b4f061414a4da710b71bf276f8dcf8171e7ff Mon Sep 17 00:00:00 2001
From: Joe Marcus Clarke <[email protected]>
Date: Sun, 13 Apr 2014 19:15:28 +0200
Subject: [PATCH 1/4] daemon: Don't try to lock and synchronise threads on
 (k)FreeBSD

Credits: Steven Chamberlain <[email protected]> is also a co-author
BugLink: http://bugs.debian.org/705435
Origin: http://svnweb.freebsd.org/ports/head/audio/pulseaudio/files/patch-src_daemon_main.c?revision=231972&view=markup&pathrev=231972
---
 src/daemon/main.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/daemon/main.c b/src/daemon/main.c
index 02a8ea6..2a4a5e0 100644
--- a/src/daemon/main.c
+++ b/src/daemon/main.c
@@ -743,6 +743,10 @@ int main(int argc, char *argv[]) {
          * first take the autospawn lock to make things
          * synchronous. */
 
+        /* This locking and thread synchronisation code doesn't work reliably
+         * on kFreeBSD (Debian bug #705435), or in upstream FreeBSD ports
+         * (bug reference: ports/128947, patched in SVN r231972). */
+#if !defined(__FreeBSD__) && !defined(__FreeBSD_kernel__)
         if ((autospawn_fd = pa_autospawn_lock_init()) < 0) {
             pa_log("Failed to initialize autospawn lock");
             goto finish;
@@ -754,6 +758,7 @@ int main(int argc, char *argv[]) {
         }
 
         autospawn_locked = true;
+#endif
     }
 
     if (conf->daemonize) {
-- 
1.7.10.4

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
pulseaudio-discuss mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss

Reply via email to