Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 26e34e9e authored by Dan Carpenter's avatar Dan Carpenter Committed by Takashi Iwai
Browse files

ALSA: usb/mixer: remove bogus cast



"uinfo->value.enumerated.item" is an unsigned int.  If it's negative
when we do the comparison:
	if ((int)uinfo->value.enumerated.item >= cval->max)
then we would read past the end of the array on the next line.

I also changed the strcpy() to strlcpy() out of paranoia.

Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 4437ecdc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment