On Sun, 22 Jul 2007, Jesper Juhl wrote:
> If, in usb_hid_configure(), we fail to allocate storage for 'usbhid',
> "if (!(usbhid = kzalloc(sizeof(struct usbhid_device), GFP_KERNEL)))",
> then we'll jump to the 'fail:' label where we have this code:
> usb_free_urb(usbhid->urbin);
> usb_free_urb(usbhid->urbout);
> usb_free_urb(usbhid->urbctrl);
> Since we got here because we couldn't allocate storage for 'usbhid',
> what we have here is a NULL pointer dereference - ouch...
Hi Jesper,
thanks a lot for noticing this, I have queued your patch in HID tree.
(and sorry for late reply, I was offline on vacation for some time).
--
Jiri Kosina
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]