diff options
author | Adrian Bunk <bunk@stusta.de> | 2006-12-20 07:34:32 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-12-27 11:19:56 -0500 |
commit | d4f60baf7827c6a46b7ee2ed0a2a32a373febfcb (patch) | |
tree | 3b4e0b7677cc022fc776f9016e323db42555b99d /drivers/media/video/cafe_ccic.c | |
parent | d82d418a3af4d7d07151f9d45ca20f2ce61289a0 (diff) |
V4L/DVB (4991): Cafe_ccic.c: fix NULL dereference
We shouldn't dereference "cam" when we already know it's NULL.
Spotted by the Coverity checker.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cafe_ccic.c')
-rw-r--r-- | drivers/media/video/cafe_ccic.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/video/cafe_ccic.c b/drivers/media/video/cafe_ccic.c index e347c7ebc984..3083c8075d13 100644 --- a/drivers/media/video/cafe_ccic.c +++ b/drivers/media/video/cafe_ccic.c | |||
@@ -2166,7 +2166,7 @@ static void cafe_pci_remove(struct pci_dev *pdev) | |||
2166 | struct cafe_camera *cam = cafe_find_by_pdev(pdev); | 2166 | struct cafe_camera *cam = cafe_find_by_pdev(pdev); |
2167 | 2167 | ||
2168 | if (cam == NULL) { | 2168 | if (cam == NULL) { |
2169 | cam_warn(cam, "pci_remove on unknown pdev %p\n", pdev); | 2169 | printk(KERN_WARNING "pci_remove on unknown pdev %p\n", pdev); |
2170 | return; | 2170 | return; |
2171 | } | 2171 | } |
2172 | mutex_lock(&cam->s_mutex); | 2172 | mutex_lock(&cam->s_mutex); |