[patch]fix oops in cdc-wdm in case of malformed descriptors

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



cdc-wdm needs to ignore extremely malformed descriptors.
Signed-off-by: Oliver Neukum <oliver@xxxxxxxxxx>
Hi,
this should go into 2.6.30 and the stable tree.
	Regards		Oliver
---
commit 7fadd86d5de05ab6232d7c8edd0571f2735e0cd4Author: Oliver Neukum <oneukum@xxxxxxxxxxxxxxx>Date:   Sat Apr 4 09:19:56 2009 +0200
    fail gracefully if confronted with malformed device descriptors    in cdc-wdm
diff --git a/drivers/usb/class/cdc-wdm.c b/drivers/usb/class/cdc-wdm.cindex 3771d6e..34e6108 100644--- a/drivers/usb/class/cdc-wdm.c+++ b/drivers/usb/class/cdc-wdm.c@@ -652,7 +652,7 @@ next_desc:  	iface = &intf->altsetting[0]; 	ep = &iface->endpoint[0].desc;-	if (!usb_endpoint_is_int_in(ep)) {+	if (!ep || !usb_endpoint_is_int_in(ep)) { 		rv = -EINVAL; 		goto err; 	}ÿôèº{.nÇ+?·?®?­?+%?Ëÿ±éݶ¥?wÿº{.nÇ+?·¥?{±þëþ)í?æèw*jg¬±¨¶????Ý¢jÿ¾«þG«?éÿ¢¸¢·¦j:+v?¨?wèjØm¶?ÿþø¯ù®w¥þ?àþf£¢·h??â?úÿ?Ù¥


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux