[vlc-devel] [PATCH 2/2] jack: lock ringbuffer in memory

Rémi Denis-Courmont remi at remlab.net
Fri May 3 06:01:03 CEST 2013


On Thu,  2 May 2013 11:48:51 -0400, Tristan Matthews
<le.businessman at gmail.com> wrote:
> The ringbuffer will be locked and later unlocked (during
> jack_ringbuffer_free),
> on systems which implement mlock().
> ---
>  modules/audio_output/jack.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/modules/audio_output/jack.c b/modules/audio_output/jack.c
> index 9d8b50f..21e194b 100644
> --- a/modules/audio_output/jack.c
> +++ b/modules/audio_output/jack.c
> @@ -175,6 +175,13 @@ static int Start( audio_output_t *p_aout,
> audio_sample_format_t *restrict fmt )
>          goto error_out;
>      }
>  
> +    if( jack_ringbuffer_mlock( p_sys->p_jack_ringbuffer ))
> +    {
> +        msg_Err( p_aout, "failed to lock JACK ringbuffer in memory" );
> +        status = VLC_EGENERIC;
> +        goto error_out;
> +    }

Fine with me, but why did that become a fatal error?

> +
>      /* Create the output ports */
>      for( i = 0; i < p_sys->i_channels; i++ )
>      {

-- 
Rémi Denis-Courmont
Sent from my collocated server



More information about the vlc-devel mailing list