]> git.baikalelectronics.ru Git - kernel.git/commit
ray_cs: read past the end of the array
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 26 Feb 2013 10:04:51 +0000 (13:04 +0300)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 6 Mar 2013 21:25:47 +0000 (16:25 -0500)
commit71a1d061385a01bb3ef33af7583b72cf4f88758b
treeb0f8f602260e4fdf03345fcc0fd25fa183d7d121
parentb73b1022ccbfd4f01203b10f4ba9c0852a3877e7
ray_cs: read past the end of the array

"translate" should either be set or disabled.  We also use it an
offset into the framing[] array when we're generating the proc
file.  Framing looks like this:

static const char *framing[] = { "Encapsulation", "Translation" }

So when we're setting translate we need to restrict the values to
either 1 or 0 or it can an out of bounds read.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ray_cs.c