summaryrefslogtreecommitdiff
path: root/drivers/media
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2012-08-14 10:03:35 +0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-08-16 01:53:29 +0400
commit0590c7130dfb88ddc7bbecd343efae1d3623f209 (patch)
treea1758e2cceea8ef4d735dae0290f6f84a3a830ed /drivers/media
parentf367cc1efebdfacfca083e55fdeafa0163054995 (diff)
downloadlinux-0590c7130dfb88ddc7bbecd343efae1d3623f209.tar.xz
[media] stk1160: remove unneeded check
"card" is a valid pointer here because we checked snd_card_create() for error returns. Checking after a dereference makes the static checkers complain. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Ezequiel Garcia <elezegarcia@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/usb/stk1160/stk1160-ac97.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/usb/stk1160/stk1160-ac97.c b/drivers/media/usb/stk1160/stk1160-ac97.c
index 8d325f50c87b..c8583c262c3d 100644
--- a/drivers/media/usb/stk1160/stk1160-ac97.c
+++ b/drivers/media/usb/stk1160/stk1160-ac97.c
@@ -133,8 +133,7 @@ int stk1160_ac97_register(struct stk1160 *dev)
err:
dev->snd_card = NULL;
- if (card)
- snd_card_free(card);
+ snd_card_free(card);
return rc;
}