Re: [RFC 1/8] usb: gadget: f_uvc: fix potential memory leak

2014-06-16 Thread Laurent Pinchart
Hi Andrzej, Thank you for the patch. On Friday 28 February 2014 10:32:23 Andrzej Pietrasiewicz wrote: > If uvc->control_buf is successfuly allocated but uvc->control_req > is not, uvc->control_buf is not freed in the error recovery path. > With this patch applied uvc->control_buf is freed uncondi

Re: [RFC 1/8] usb: gadget: f_uvc: fix potential memory leak

2014-03-07 Thread Sebastian Andrzej Siewior
On 02/28/2014 10:32 AM, Andrzej Pietrasiewicz wrote: > If uvc->control_buf is successfuly allocated but uvc->control_req > is not, uvc->control_buf is not freed in the error recovery path. > With this patch applied uvc->control_buf is freed unconditionally; > if it happens to be NULL kfree on it is

[RFC 1/8] usb: gadget: f_uvc: fix potential memory leak

2014-02-28 Thread Andrzej Pietrasiewicz
If uvc->control_buf is successfuly allocated but uvc->control_req is not, uvc->control_buf is not freed in the error recovery path. With this patch applied uvc->control_buf is freed unconditionally; if it happens to be NULL kfree on it is safe anyway. Signed-off-by: Andrzej Pietrasiewicz --- dri