]> git.baikalelectronics.ru Git - kernel.git/commit
V4L/DVB (10619): gspca - main: Destroy the URBs at disconnection time.
authorAdam Baker <linux@baker-net.org.uk>
Wed, 4 Feb 2009 18:33:21 +0000 (15:33 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 17 Feb 2009 12:43:09 +0000 (09:43 -0300)
commite1e28e8b3b3eace15a257ccc7d8a944dd2e303bb
tree1cdc54428ff54a316d212c7beeb13791cdac248b
parent7b0779967ff0a13b38a0d44972c575f13e774540
V4L/DVB (10619): gspca - main: Destroy the URBs at disconnection time.

If a device using the gspca framework is unplugged while it is still streaming
then the call that is used to free the URBs that have been allocated occurs
after the pointer it uses becomes invalid at the end of gspca_disconnect.
Make another cleanup call in gspca_disconnect while the pointer is still
valid (multiple calls are OK as destroy_urbs checks for pointers already
being NULL.

Signed-off-by: Adam Baker <linux@baker-net.org.uk>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/gspca/gspca.c