Author: rmudgett Date: Fri Dec 19 11:41:01 2014 New Revision: 429831 URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=429831 Log: chan_dahdi: Don't ignore setvar when using configuration section scheme.
When the configuration section scheme of chan_dahdi.conf is used (keyword dahdichan instead of channel) all setvar= options are completely ignored. No variable defined this way appears in the created DAHDI channels. * Move the clearing of setvar values to after the deferred processing of dahdichan. AST-1378 #close Reported by: Guenther Kelleter Patch by: Guenther Kelleter ........ Merged revisions 429825 from http://svn.asterisk.org/svn/asterisk/branches/11 Modified: certified/branches/11.6/ (props changed) certified/branches/11.6/channels/chan_dahdi.c Propchange: certified/branches/11.6/ ------------------------------------------------------------------------------ Binary property 'branch-11-merged' - no diff available. Modified: certified/branches/11.6/channels/chan_dahdi.c URL: http://svnview.digium.com/svn/asterisk/certified/branches/11.6/channels/chan_dahdi.c?view=diff&rev=429831&r1=429830&r2=429831 ============================================================================== --- certified/branches/11.6/channels/chan_dahdi.c (original) +++ certified/branches/11.6/channels/chan_dahdi.c Fri Dec 19 11:41:01 2014 @@ -18577,12 +18577,6 @@ ast_log(LOG_WARNING, "Ignoring any changes to '%s' (on reload) at line %d.\n", v->name, v->lineno); } - /* Since confp has already filled invidual dahdi_pvt objects with channels at this point, clear the variables in confp's pvt. */ - if (confp->chan.vars) { - ast_variables_destroy(confp->chan.vars); - confp->chan.vars = NULL; - } - if (dahdichan) { /* Process the deferred dahdichan value. */ if (build_channels(confp, dahdichan->value, reload, dahdichan->lineno, @@ -18595,6 +18589,15 @@ return -1; } } + } + + /* + * Since confp has already filled individual dahdi_pvt objects with channels + * at this point, clear the variables in confp's pvt. + */ + if (confp->chan.vars) { + ast_variables_destroy(confp->chan.vars); + confp->chan.vars = NULL; } /* mark the first channels of each DAHDI span to watch for their span alarms */ -- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- svn-commits mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/svn-commits
