Re: [PATCH] sound, hda_eld: suspicious sizeof() in call tosnd_print_pcm_bits()

From: Wu Fengguang
Date: Sat Jan 29 2011 - 05:46:44 EST


On Sat, Jan 29, 2011 at 01:40:04AM +0100, Jesper Juhl wrote:

> if (a->format == AUDIO_CODING_TYPE_LPCM)
> - snd_print_pcm_bits(a->sample_bits, buf2 + 8, sizeof(buf2 - 8));
> + snd_print_pcm_bits(a->sample_bits, buf2 + 8, sizeof(buf2) - 8);

Good catch!

Reviewed-by: Wu Fengguang <fengguang.wu@xxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/