isdn: hfc_usb: Fix read buffer overflow
commitb02f6a9593cbe0c3a9cf6052acf58c11980d6efd
authorRoel Kluin <roel.kluin@gmail.com>
Wed, 4 Nov 2009 16:31:59 +0000 (4 08:31 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 8 Dec 2009 18:22:52 +0000 (8 10:22 -0800)
tree33bdac95ab543b8647908c2835393d6a816b7b36
parent548193715cb69952c6655f8800d81a8bfe2d8bc5
isdn: hfc_usb: Fix read buffer overflow

commit 286e633ef0ff5bb63c07b4516665da8004966fec upstream.

Check whether index is within bounds before testing the element.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Cc: Karsten Keil <isdn@linux-pingi.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/isdn/hisax/hfc_usb.c