From: Hans de Goede Date: Tue, 26 Oct 2010 08:16:32 +0000 (-0300) Subject: [media] gspca: only set gspca->int_urb if submitting it succeeds X-Git-Tag: v2.6.38-rc1~470^2~237 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2661da47daefd4f22f9fdc7e9294a1cb9edf515b;p=pandora-kernel.git [media] gspca: only set gspca->int_urb if submitting it succeeds Currently alloc_and_submit_int_urb() is setting gspca->int_urb as soon as the allocation has succeeded, but if the subsequent submit fails, the urb gets destroyed. And then later will get destroyed again in gspca_input_destroy_urb() because gspca->int_urb is set, leading to a double free. Signed-off-by: Hans de Goede Signed-off-by: Mauro Carvalho Chehab --- Reading git-diff-tree failed