diff mbox

konicawc.c: possible buffer overflow while use strncat.

Message ID 200910071556.59139.strakh@ispras.ru (mailing list archive)
State Accepted
Headers show

Commit Message

iceberg Oct. 7, 2009, 3:56 p.m. UTC
None
diff mbox

Patch

diff --git a/./a/drivers/media/video/usbvideo/konicawc.c 
b/./b/drivers/media/video/usbvideo/konicawc.c
index 31d57f2..a0addcb 100644
--- a/./a/drivers/media/video/usbvideo/konicawc.c
+++ b/./b/drivers/media/video/usbvideo/konicawc.c
@@ -225,7 +225,7 @@  static void konicawc_register_input(struct konicawc *cam, 
struct usb_device *dev
 	int error;
 
 	usb_make_path(dev, cam->input_physname, sizeof(cam->input_physname));
-	strncat(cam->input_physname, "/input0", sizeof(cam->input_physname));
+	strlcat(cam->input_physname, "/input0", sizeof(cam->input_physname));
 
 	cam->input = input_dev = input_allocate_device();