[CinCV TNG] [PATCH] Fixed compiler warning about depreciated alsa functions

Johannes Sixt j6t at kdbg.org
Sun Jul 2 13:48:11 CEST 2017


Am 30.06.2017 um 21:46 schrieb Einar R√ľnkaru:
> Removed depreciated alsa API functions.
> ---
>   cinelerra/audioalsa.C | 4 ----
>   1 file changed, 4 deletions(-)
> 
> diff --git a/cinelerra/audioalsa.C b/cinelerra/audioalsa.C
> index c38048b..1f86e19 100644
> --- a/cinelerra/audioalsa.C
> +++ b/cinelerra/audioalsa.C
> @@ -285,12 +285,8 @@ int AudioALSA::set_params(snd_pcm_t *dsp,
>   //printf("AudioALSA::set_params 10 %d %d\n", chunk_size, buffer_size);
>   
>   	snd_pcm_sw_params_current(dsp, swparams);
> -	size_t xfer_align = 1 /* snd_pcm_sw_params_get_xfer_align(swparams) */;
> -	unsigned int sleep_min = 0;
> -	err = snd_pcm_sw_params_set_sleep_min(dsp, swparams, sleep_min);
>   	int n = chunk_size;
>   	err = snd_pcm_sw_params_set_avail_min(dsp, swparams, n);
> -	err = snd_pcm_sw_params_set_xfer_align(dsp, swparams, xfer_align);
>   	if(snd_pcm_sw_params(dsp, swparams) < 0)
>   	{
>   		fprintf(stderr, "AudioALSA::set_params: snd_pcm_sw_params failed\n");

Deprecated does not mean unusable or unnecessary. Why do we not need 
these function calls?

-- Hannes


More information about the Cinelerra mailing list