From: Mike Isely Date: Sat, 15 May 2010 03:28:44 +0000 (-0300) Subject: V4L/DVB: pvrusb2: Fix minor internal array allocation X-Git-Tag: v3.0~4402^2~78 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7a6ac34848226e315e0d70333bb4ab83190d9f1d;p=platform%2Fkernel%2Flinux-amlogic.git V4L/DVB: pvrusb2: Fix minor internal array allocation pvrusb2: Need one extra attribute slot allocated so that worst case still has a trailing null pointer. This wasn't causing visible symptoms; it was found through inspection while investigating other issues. Signed-off-by: Mike Isely Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/pvrusb2/pvrusb2-sysfs.c b/drivers/media/video/pvrusb2/pvrusb2-sysfs.c index bf47851..3d7e5aab 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-sysfs.c +++ b/drivers/media/video/pvrusb2/pvrusb2-sysfs.c @@ -74,7 +74,7 @@ struct pvr2_sysfs_ctl_item { int ctl_id; struct pvr2_sysfs *chptr; struct pvr2_sysfs_ctl_item *item_next; - struct attribute *attr_gen[7]; + struct attribute *attr_gen[8]; struct attribute_group grp; int created_ok; char name[80];