From owner-freebsd-multimedia@FreeBSD.ORG Sat Nov 17 18:05:44 2012 Return-Path: Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7E02C9FD for ; Sat, 17 Nov 2012 18:05:44 +0000 (UTC) (envelope-from rhurlin@gwdg.de) Received: from amailer.gwdg.de (amailer.gwdg.de [134.76.10.18]) by mx1.freebsd.org (Postfix) with ESMTP id 0E2058FC12 for ; Sat, 17 Nov 2012 18:05:43 +0000 (UTC) Received: from p5dc3ee0b.dip.t-dialin.net ([93.195.238.11] helo=krabat.raven.hur) by mailer.gwdg.de with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.72) (envelope-from ) id 1TZmlv-0008SN-WE; Sat, 17 Nov 2012 19:05:40 +0100 Message-ID: <50A7D1F3.1080407@gwdg.de> Date: Sat, 17 Nov 2012 19:05:39 +0100 From: Rainer Hurling User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:16.0) Gecko/20121114 Thunderbird/16.0.2 MIME-Version: 1.0 To: Juergen Lock Subject: Re: VLC 2.0.4 audio output module Pulseaudio seg faults References: <50A783EC.3080801@gwdg.de> <20121117164027.GA74542@triton8.kn-bremen.de> In-Reply-To: <20121117164027.GA74542@triton8.kn-bremen.de> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Authenticated: Id:rhurlin X-Spam-Level: - X-Virus-Scanned: (clean) by exiscan+sophie Cc: freebsd-multimedia@freebsd.org X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Nov 2012 18:05:44 -0000 On 17.11.2012 17:40 (UTC+2), Juergen Lock wrote: > On Sat, Nov 17, 2012 at 01:32:44PM +0100, Rainer Hurling wrote: >> While vlc versions up to 2.0.3 runs fine using pulseaudio output module, >> unfortunately version 2.0.4 immediately seg faults. >> >> When I change from pulseaudio output to any other audio output module >> vlc does not crash. >> >> Is this a know issue? Are there any workarounds? I really need >> pulseaudio for my sound system. >> >> My box is running on latest 10.0-CURRENT amd64. Please let me know if I >> should provide more information. >> > Whoops that is a funny bug. Does the patch below fix it? (put it in > files/patch-modules-audio_output-vlcpulse.c ) > > Thanx! > Juergen Moin Juergen, while I am writing these lines I am listening vlc with pulseaudio output again :-) So obviously the patch helped. Many thanks and have a nice weekend, Rainer > --- modules/audio_output/vlcpulse.c.orig > +++ modules/audio_output/vlcpulse.c > @@ -113,10 +113,12 @@ pa_context *vlc_pa_connect (vlc_object_t > struct passwd pwbuf, *pw; > char buf[len]; > > - if (getpwuid_r (getuid (), &pwbuf, buf, sizeof (buf), &pw) == 0 > - && pw != NULL) > - pa_proplist_sets (props, PA_PROP_APPLICATION_PROCESS_USER, > - pw->pw_name); > + if (getpwuid_r (getuid (), &pwbuf, buf, sizeof (buf), &pw) == 0) { > + if (pw != NULL) > + pa_proplist_sets (props, PA_PROP_APPLICATION_PROCESS_USER, > + pw->pw_name); > + break; > + } > } > > for (size_t max = sysconf (_SC_HOST_NAME_MAX), len = max % 1024 + 1024; > @@ -124,9 +126,11 @@ pa_context *vlc_pa_connect (vlc_object_t > { > char hostname[len]; > > - if (gethostname (hostname, sizeof (hostname)) == 0) > + if (gethostname (hostname, sizeof (hostname)) == 0) { > pa_proplist_sets (props, PA_PROP_APPLICATION_PROCESS_HOST, > hostname); > + break; > + } > } > > const char *session = getenv ("XDG_SESSION_COOKIE"); >