summaryrefslogtreecommitdiff
path: root/linux/drivers/media
diff options
context:
space:
mode:
authorPatrick Boettcher <pb@linuxtv.org>2006-08-02 14:26:27 +0200
committerPatrick Boettcher <pb@linuxtv.org>2006-08-02 14:26:27 +0200
commitb5d24e3fdbcb2224e74af148395d4cca2b094384 (patch)
tree172ac60ea6f4c5fecda54820f4d13eea3df1c4b4 /linux/drivers/media
parent13fdda6d96be65a0ccdca2c56355808fa130ee8f (diff)
downloadmediapointer-dvb-s2-b5d24e3fdbcb2224e74af148395d4cca2b094384.tar.gz
mediapointer-dvb-s2-b5d24e3fdbcb2224e74af148395d4cca2b094384.tar.bz2
DiB3000MC: set FE to NULL after being freed
From: Patrick Boettcher <pb@linuxtv.org> DiB3000MC: set FE to NULL after being freed Signed-off-by: Patrick Boettcher <pb@linuxtv.org>
Diffstat (limited to 'linux/drivers/media')
-rw-r--r--linux/drivers/media/dvb/dvb-usb/dvb-usb-dvb.c2
-rw-r--r--linux/drivers/media/dvb/frontends/dib3000mc.c5
-rw-r--r--linux/drivers/media/dvb/frontends/dibx000_common.h2
3 files changed, 5 insertions, 4 deletions
diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb-dvb.c b/linux/drivers/media/dvb/dvb-usb/dvb-usb-dvb.c
index 9dfa3e24d..fe6208ada 100644
--- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-dvb.c
+++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-dvb.c
@@ -175,7 +175,7 @@ static int dvb_usb_fe_sleep(struct dvb_frontend *fe)
int dvb_usb_fe_init(struct dvb_usb_device* d)
{
if (d->props.frontend_attach == NULL) {
- err("strange '%s' doesn't want to attach a frontend.",d->desc->name);
+ err("strange: '%s' doesn't want to attach a frontend.",d->desc->name);
return 0;
}
diff --git a/linux/drivers/media/dvb/frontends/dib3000mc.c b/linux/drivers/media/dvb/frontends/dib3000mc.c
index 3e68fd8e3..0a1369cc9 100644
--- a/linux/drivers/media/dvb/frontends/dib3000mc.c
+++ b/linux/drivers/media/dvb/frontends/dib3000mc.c
@@ -908,9 +908,10 @@ int dib3000mc_attach(struct i2c_adapter *i2c_adap, int no_of_demods, u8 default_
return 0;
error:
- for (k = 0; k < num; k++)
+ for (k = 0; k < num; k++) {
kfree(demod[k]->demodulator_priv);
-
+ demod[k] = NULL;
+ }
return -EINVAL;
}
diff --git a/linux/drivers/media/dvb/frontends/dibx000_common.h b/linux/drivers/media/dvb/frontends/dibx000_common.h
index 428999f0a..bb0c65f8a 100644
--- a/linux/drivers/media/dvb/frontends/dibx000_common.h
+++ b/linux/drivers/media/dvb/frontends/dibx000_common.h
@@ -117,7 +117,7 @@ enum dibx000_adc_states {
#define BW_INDEX_TO_KHZ(v) ( (v) == BANDWIDTH_8_MHZ ? 8000 : \
(v) == BANDWIDTH_7_MHZ ? 7000 : \
- (v) == BANDWIDTH_6_MHZ ? 6000 : 8000 )
+ (v) == BANDWIDTH_6_MHZ ? 6000 : 8000 )
/* Chip output mode. */
#define OUTMODE_HIGH_Z 0