From: Dan Carpenter Date: Mon, 19 Oct 2015 11:29:27 +0000 (+0300) Subject: ALSA: firewire-tascam: off by one in identify_model() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9a30ae2df29c27eca58581862928ee2c7bbdfa76;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git ALSA: firewire-tascam: off by one in identify_model() Let's leave space for the NUL char otherwise the static checkers complain that we go beyond the end of the array. Fixes: 53b3ffee7885 ('ALSA: firewire-tascam: change device probing processing') Signed-off-by: Dan Carpenter Reviewed-by: Takashi Sakamoto Signed-off-by: Takashi Iwai --- diff --git a/sound/firewire/tascam/tascam.c b/sound/firewire/tascam/tascam.c index c2f42cd3f3b8..ee0bc1839508 100644 --- a/sound/firewire/tascam/tascam.c +++ b/sound/firewire/tascam/tascam.c @@ -40,7 +40,7 @@ static int identify_model(struct snd_tscm *tscm) { struct fw_device *fw_dev = fw_parent_device(tscm->unit); const u32 *config_rom = fw_dev->config_rom; - char model[8]; + char model[9]; unsigned int i; u8 c;