[PATCH 31/37] dvb: nxt200x: check callback fix

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





Check that a callback (set_ts_params) is set before calling it.

Signed-off-by: Michael Krufky <[email protected]>

 drivers/media/dvb/frontends/nxt200x.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

--- linux-2.6.14-git3.orig/drivers/media/dvb/frontends/nxt200x.c
+++ linux-2.6.14-git3/drivers/media/dvb/frontends/nxt200x.c
@@ -557,14 +557,16 @@
 		case QAM_256:
 			/* Set punctured clock for QAM */
 			/* This is just a guess since I am unable to test it */
-			state->config->set_ts_params(fe, 1);
+			if (state->config->set_ts_params)
+				state->config->set_ts_params(fe, 1);
 
 			/* set to use cable input */
 			buf[3] |= 0x08;
 			break;
 		case VSB_8:
 			/* Set non-punctured clock for VSB */
-			state->config->set_ts_params(fe, 0);
+			if (state->config->set_ts_params)
+				state->config->set_ts_params(fe, 0);
 			break;
 		default:
 			return -EINVAL;


[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux