staging: speakup: avoid out-of-range access in synth_add()
authorSamuel Thibault <samuel.thibault@ens-lyon.org>
Mon, 7 Jan 2013 21:03:51 +0000 (22:03 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 7 Jan 2013 21:53:28 +0000 (13:53 -0800)
commit6102c48bd421074a33e102f2ebda3724e8d275f9
tree44f791324fb19dba052e5eb61efe5afe324af6bd
parentae428655b826f2755a8101b27beda42a275ef8ad
staging: speakup: avoid out-of-range access in synth_add()

Check that array index is in-bounds before accessing the synths[] array.

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Cc: stable <stable@vger.kernel.org>
Cc: Nickolai Zeldovich <nickolai@csail.mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/speakup/synth.c