diff options
author | Erik Andrén <erik.andren@gmail.com> | 2008-10-13 14:52:46 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-10-17 16:40:18 -0400 |
commit | 447328194efa74aba45c656b47a98c58487a28f6 (patch) | |
tree | 3df65f867235942376d92984fea906e94f183153 /drivers/media/video | |
parent | e2c974919f03a8c1a2ce9797ecab63468e9ec4ef (diff) |
V4L/DVB (9282): Properly iterate the urbs when destroying them.
Properly iterate the allocated when freeing the urbs, this fixes a memory leak
Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video')
-rw-r--r-- | drivers/media/video/gspca/gspca.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/video/gspca/gspca.c b/drivers/media/video/gspca/gspca.c index c21af312ee7c..277244b1fd75 100644 --- a/drivers/media/video/gspca/gspca.c +++ b/drivers/media/video/gspca/gspca.c | |||
@@ -403,7 +403,7 @@ static void destroy_urbs(struct gspca_dev *gspca_dev) | |||
403 | unsigned int i; | 403 | unsigned int i; |
404 | 404 | ||
405 | PDEBUG(D_STREAM, "kill transfer"); | 405 | PDEBUG(D_STREAM, "kill transfer"); |
406 | for (i = 0; i < MAX_NURBS; ++i) { | 406 | for (i = 0; i < MAX_NURBS; i++) { |
407 | urb = gspca_dev->urb[i]; | 407 | urb = gspca_dev->urb[i]; |
408 | if (urb == NULL) | 408 | if (urb == NULL) |
409 | break; | 409 | break; |