]> git.karo-electronics.de Git - karo-tx-linux.git/commit
keyboard: integer underflow bug
authorDan Carpenter <error27@gmail.com>
Thu, 3 Mar 2011 16:56:06 +0000 (17:56 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 14 Mar 2011 21:29:53 +0000 (14:29 -0700)
commitd5719ed81492a21fa0ba5b10ba366153f2b49fb3
tree1c6a84f4c6687f56c1c8f2342f3c413669088dca
parentcf666a4bfee9de4378566819081e9451a0fe6f1f
keyboard: integer underflow bug

commit b652277b09d3d030cb074cc6a98ba80b34244c03 upstream.

The "ct" variable should be an unsigned int.  Both struct kbdiacrs
->kb_cnt and struct kbd_data ->accent_table_size are unsigned ints.

Making it signed causes a problem in KBDIACRUC because the user could
set the signed bit and cause a buffer overflow.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/s390/char/keyboard.c