[PATCH 1/2] modargs: Fix pa_modargs_get_sample_rate() if no "rate" is present in the modargs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2013-12-11 at 17:07 +0100, Peter Meerwald wrote:
> From: Peter Meerwald <p.meerwald at bct-electronic.com>
> 
> see http://lists.freedesktop.org/archives/pulseaudio-discuss/2013-December/019471.html
> 
> Signed-off-by: Peter Meerwald <pmeerw at pmeerw.net>
> Reported-by: "poljar (Damir Jeli?)" <poljarinho at gmail.com>
> ---
>  src/pulsecore/modargs.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/src/pulsecore/modargs.c b/src/pulsecore/modargs.c
> index 432e480..6855b6a 100644
> --- a/src/pulsecore/modargs.c
> +++ b/src/pulsecore/modargs.c
> @@ -369,6 +369,7 @@ int pa_modargs_get_sample_rate(pa_modargs *ma, uint32_t *rate) {
>  
>      pa_assert(rate);
>  
> +    rate_local = *rate;
>      if ((pa_modargs_get_value_u32(ma, "rate", &rate_local)) < 0 ||
>          rate_local <= 0 ||
>          rate_local > PA_RATE_MAX)

Thanks Peter and poljar, I pushed both of these patches.

-- 
Tanu



[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux