ChangeSet 1.1322, 2003/05/30 10:25:23-07:00, [EMAIL PROTECTED]
[PATCH] USB: name uninitialized in scanner.c
Linux 2.5.69-bk18 prints something strange to the kernel log when the USB
scanner is attached. It turns out drivers/usb/image/scanner.c uses
uninitialized variable "name" in probe_scanner() in the printk() call.
That means that random memory is read and output to the kernel log.
drivers/usb/image/scanner.c | 3 +++
1 files changed, 3 insertions(+)
diff -Nru a/drivers/usb/image/scanner.c b/drivers/usb/image/scanner.c
--- a/drivers/usb/image/scanner.c Fri May 30 11:34:48 2003
+++ b/drivers/usb/image/scanner.c Fri May 30 11:34:48 2003
@@ -1106,6 +1106,9 @@
scn->scn_minor = intf->minor;
scn->isopen = 0;
+ snprintf(name, sizeof(name), scanner_class.name,
+ intf->minor - scanner_class.minor_base);
+
info ("USB scanner device (0x%04x/0x%04x) now attached to %s",
dev->descriptor.idVendor, dev->descriptor.idProduct, name);
-------------------------------------------------------
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel