tridentfb: fix pseudo_palette array overrun in setcolreg
authorAntonino A. Daplas <adaplas@gmail.com>
Tue, 17 Jul 2007 11:05:41 +0000 (04:05 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Tue, 17 Jul 2007 17:23:12 +0000 (10:23 -0700)
commit973d9ab231a6b9feb1ff5b9a072f11756eca96cc
treefefef9f4bd86989579a8b6496dfc09faba19acf8
parenteb3daa83c2f63743fb7597f620beac75e1ba5633
tridentfb: fix pseudo_palette array overrun in setcolreg

The pseudo_palette has only 16 elements. Do not write if regno (the array
index) is more than 15.

Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/video/tridentfb.c