[svn-commits] sruffell: linux/trunk r6801 - /linux/trunk/drivers/dahdi/dahdi-base.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Jun 30 12:17:13 CDT 2009


Author: sruffell
Date: Tue Jun 30 12:17:09 2009
New Revision: 6801

URL: http://svn.asterisk.org/svn-view/dahdi?view=rev&rev=6801
Log:
echocan: Do not call through NULL 'echocan_traintap' pointer.

This resolves an issue with a kernel panic if echotraining is enabled in the
Asterisk configuration file, but the echocan on the channel (which may be a
hardware echocanceller) has not defined that operation. DAHDI-272.

Modified:
    linux/trunk/drivers/dahdi/dahdi-base.c

Modified: linux/trunk/drivers/dahdi/dahdi-base.c
URL: http://svn.asterisk.org/svn-view/dahdi/linux/trunk/drivers/dahdi/dahdi-base.c?view=diff&rev=6801&r1=6800&r2=6801
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi-base.c (original)
+++ linux/trunk/drivers/dahdi/dahdi-base.c Tue Jun 30 12:17:09 2009
@@ -6688,7 +6688,8 @@
 					ss->ec_state->status.last_train_tap = 0;
 					ss->ec_state->status.mode = ECHO_MODE_TRAINING;
 				}
-				if (ss->ec_state->status.mode == ECHO_MODE_TRAINING) {
+				if ((ss->ec_state->status.mode == ECHO_MODE_TRAINING) &&
+				    (ss->ec_state->ops->echocan_traintap)) {
 					if (ss->ec_state->ops->echocan_traintap(ss->ec_state, ss->ec_state->status.last_train_tap++, rxlin)) {
 #if 0
 						module_printk(KERN_NOTICE, "Finished training (%d taps trained)!\n", ss->ec_state->status.last_train_tap);




More information about the svn-commits mailing list