Re: [alsa-devel] [PATCH 8/8] coverity fix in alsa-libs
Hi, Bug Type : Null check before closing h Files changed : pcm_hooks.c PFA patch8
Thanks Renu Tyagi ------------------------------------------------------------------------- From 906a8b65911edfd9d8bef48450707685bf4b8980 Mon Sep 17 00:00:00 2001 From: renu tyagi renu.tyagi@samsung.com Date: Thu, 18 Sep 2014 16:45:59 +0530 Subject: [PATCH 8/8] [pcm_hooks] : Null check before closing h
Signed-off-by: renu tyagi renu.tyagi@samsung.com --- src/pcm/pcm_hooks.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/src/pcm/pcm_hooks.c b/src/pcm/pcm_hooks.c index 0b93c64..ce1cf36 100644 --- a/src/pcm/pcm_hooks.c +++ b/src/pcm/pcm_hooks.c @@ -457,7 +457,8 @@ static int snd_pcm_hook_add_conf(snd_pcm_t *pcm, snd_config_t *root, snd_config_ err = hook_add_dlobj(pcm, h);
if (err < 0) { - snd_dlclose(h); + if(h) + snd_dlclose(h); return err; } return 0; -- 1.7.1
participants (1)
-
Renu Tyagi