diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-09-04 10:19:27 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-09-04 10:19:27 -0400 |
commit | 627d49e4be1d62e3a0f37790f77640d47332ca3f (patch) | |
tree | f409968c6cec1b3bc93617dc8c70a735071602c2 /linux/drivers/media/video/w9968cf.c | |
parent | 5b13fd9ada96757a97270032bc1cf1d2f90036e2 (diff) | |
download | mediapointer-dvb-s2-627d49e4be1d62e3a0f37790f77640d47332ca3f.tar.gz mediapointer-dvb-s2-627d49e4be1d62e3a0f37790f77640d47332ca3f.tar.bz2 |
w9968cf: Fix order of usb_alloc_urb validation
From: Douglas Schilling Landgraf <dougsland@linuxtv.org>
Fixed order of usb_alloc_urb pointer validation.
Priority: high
Signed-off-by: Douglas Schilling Landgraf <dougsland@linuxtv.org>
CC: Luca Risolia <luca.risolia@studio.unibo.it>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video/w9968cf.c')
-rw-r--r-- | linux/drivers/media/video/w9968cf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/linux/drivers/media/video/w9968cf.c b/linux/drivers/media/video/w9968cf.c index 666438e8d..4e7a8400b 100644 --- a/linux/drivers/media/video/w9968cf.c +++ b/linux/drivers/media/video/w9968cf.c @@ -919,7 +919,6 @@ static int w9968cf_start_transfer(struct w9968cf_device* cam) for (i = 0; i < W9968CF_URBS; i++) { urb = usb_alloc_urb(W9968CF_ISO_PACKETS, GFP_KERNEL); - cam->urb[i] = urb; if (!urb) { for (j = 0; j < i; j++) usb_free_urb(cam->urb[j]); @@ -927,6 +926,7 @@ static int w9968cf_start_transfer(struct w9968cf_device* cam) return -ENOMEM; } + cam->urb[i] = urb; urb->dev = udev; urb->context = (void*)cam; urb->pipe = usb_rcvisocpipe(udev, 1); |