lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 14 May 2014 16:47:08 +0200
From:	Takashi Iwai <tiwai@...e.de>
To:	Dan Carpenter <dan.carpenter@...cle.com>
Cc:	Jaroslav Kysela <perex@...ex.cz>, alsa-devel@...a-project.org,
	linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: [patch] ALSA: sb_mixer: missing return statement

At Wed, 14 May 2014 16:32:21 +0300,
Dan Carpenter wrote:
> 
> The if condition here was supposed to return on error but the return
> statement is missing.  The effect is that the ->mixername is set to
> "???" instead of "DT019X".
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>

Thanks, applied.


Takashi

> 
> diff --git a/sound/isa/sb/sb_mixer.c b/sound/isa/sb/sb_mixer.c
> index 6496822..1ff78ec 100644
> --- a/sound/isa/sb/sb_mixer.c
> +++ b/sound/isa/sb/sb_mixer.c
> @@ -818,12 +818,14 @@ int snd_sbmixer_new(struct snd_sb *chip)
>  			return err;
>  		break;
>  	case SB_HW_DT019X:
> -		if ((err = snd_sbmixer_init(chip,
> -					    snd_dt019x_controls,
> -					    ARRAY_SIZE(snd_dt019x_controls),
> -					    snd_dt019x_init_values,
> -					    ARRAY_SIZE(snd_dt019x_init_values),
> -					    "DT019X")) < 0)
> +		err = snd_sbmixer_init(chip,
> +				       snd_dt019x_controls,
> +				       ARRAY_SIZE(snd_dt019x_controls),
> +				       snd_dt019x_init_values,
> +				       ARRAY_SIZE(snd_dt019x_init_values),
> +				       "DT019X");
> +		if (err < 0)
> +			return err;
>  		break;
>  	default:
>  		strcpy(card->mixername, "???");
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ