diff options
author | Sylwester Nawrocki <s.nawrocki@samsung.com> | 2011-02-11 10:33:06 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-03-22 03:54:14 -0400 |
commit | a0f8caefaf3295721ef00415c7d63ec10af253ab (patch) | |
tree | 205e220beaa968f127937777ab51d9076963d12d /drivers | |
parent | 8ec737ffccd7fab629e28427b4d0581ce62ffedd (diff) |
[media] s5p-fimc: Prevent oops when i2c adapter is not available
Prevent invalid pointer dereference on error path.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/media/video/s5p-fimc/fimc-capture.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/video/s5p-fimc/fimc-capture.c b/drivers/media/video/s5p-fimc/fimc-capture.c index 6b6f72e4066c..423931c0cfe5 100644 --- a/drivers/media/video/s5p-fimc/fimc-capture.c +++ b/drivers/media/video/s5p-fimc/fimc-capture.c | |||
@@ -98,7 +98,7 @@ static int fimc_subdev_attach(struct fimc_dev *fimc, int index) | |||
98 | continue; | 98 | continue; |
99 | 99 | ||
100 | sd = fimc_subdev_register(fimc, isp_info); | 100 | sd = fimc_subdev_register(fimc, isp_info); |
101 | if (sd) { | 101 | if (!IS_ERR_OR_NULL(sd)) { |
102 | vid_cap->sd = sd; | 102 | vid_cap->sd = sd; |
103 | vid_cap->input_index = i; | 103 | vid_cap->input_index = i; |
104 | 104 | ||