coverity fix in alsa-libs
A message that is not in the archive (sent off-list or not yet received): [email protected]
At Thu, 18 Sep 2014 11:29:51 +0000 (GMT),
Quoted 25 lines · Renu Tyagi
Hi,
Bug Type : If lib is NULL return error to avoid strlen of NULL string File changed :simple_abst.c
PFA patch6Thanks
Renu Tyagi
----------------------------------------------------------------------------------------
From052755ef6fec398f4e49bd31e9e60fe42a14ba53Mon Sep 17 00:00:00 2001
From: renu tyagi <[email protected]>
Date: Thu, 18 Sep 2014 16:41:43 +0530
Subject: [PATCH 6/8] [simple_abst] : If lib is NULL return error to avoid strlen of NULL string.Signed-off-by renu tyagi <[email protected]>--- src/mixer/simple_abst.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)src/mixer/simple_abst.c +0
-0
src/mixer/simple_abst.c static int try_open(snd_mixer_class_t *class, const char *lib) · line 75
Quoted 5 lines
src/mixer/simple_abst.c +2
-0@@ -71,6 +71,8 @@ static int try_open(snd_mixer_class_t *class, const char *lib)int err =0 ; path =getenv ("ALSA_MIXER_SIMPLE_MODULES" ); +if (!lib) +return -ENXIO ;
This should be put before getenv() call.
Please fix and resubmit?
Takashi
Quoted 5 lines
src/mixer/simple_abst.c +0
-1if (!path) path =SO_PATH ; xlib =malloc (strlen (lib) +strlen (path) +1 +1 ); --1.7.1