[pulseaudio-discuss] [PATCH] stream-interaction: Fix crash in case of invalid argument for volume

Tanu Kaskinen tanuk at iki.fi
Wed Apr 20 13:37:56 UTC 2016


On Wed, 2016-03-30 at 02:21 +0900, Sangchul Lee wrote:
> In case of invalid argument for volume, the crash occurs in pa_stream_interaction_done().
> pa_xnew() is replaced with pa_xnew0() to fix it.
> 
> Signed-off-by: Sangchul Lee <sc11.lee at samsung.com>
> ---
>  src/modules/stream-interaction.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/modules/stream-interaction.c b/src/modules/stream-interaction.c
> index 5df17c4..6dd33c5 100644
> --- a/src/modules/stream-interaction.c
> +++ b/src/modules/stream-interaction.c
> @@ -307,7 +307,7 @@ int pa_stream_interaction_init(pa_module *m, const char* const v_modargs[]) {
>          goto fail;
>      }
>  
> -    m->userdata = u = pa_xnew(struct userdata, 1);
> +    m->userdata = u = pa_xnew0(struct userdata, 1);
>  
>      u->core = m->core;
>      u->name = m->name;

Thanks, applied!

-- 
Tanu


More information about the pulseaudio-discuss mailing list