summaryrefslogtreecommitdiffstats
path: root/drivers/media/video/em28xx
diff options
context:
space:
mode:
authorChris Rankin <rankincj@yahoo.com>2011-08-20 13:08:34 +0200
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-09-04 01:49:41 +0200
commitf38f33395232db1a03d21b992af1714cbffbdec4 (patch)
tree48e85071fe8234056073c6f2e8c7aad7ed524586 /drivers/media/video/em28xx
parent[media] DVB: increment minor version after addition of SYS_TURBO (diff)
downloadlinux-f38f33395232db1a03d21b992af1714cbffbdec4.tar.xz
linux-f38f33395232db1a03d21b992af1714cbffbdec4.zip
[media] em28xx: pass correct buffer size to snprintf
snprintf()'s size parameter includes space for the terminating '\0' character. Signed-off-by: Chris Rankin <rankincj@yahoo.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/em28xx')
-rw-r--r--drivers/media/video/em28xx/em28xx-cards.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c
index 3e3959fee419..d947026e4795 100644
--- a/drivers/media/video/em28xx/em28xx-cards.c
+++ b/drivers/media/video/em28xx/em28xx-cards.c
@@ -3154,7 +3154,7 @@ static int em28xx_usb_probe(struct usb_interface *interface,
goto err;
}
- snprintf(dev->name, 29, "em28xx #%d", nr);
+ snprintf(dev->name, sizeof(dev->name), "em28xx #%d", nr);
dev->devno = nr;
dev->model = id->driver_info;
dev->alt = -1;