[svn-commits] tilghman: trunk r244505 - /trunk/channels/chan_dahdi.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Wed Feb 3 12:34:35 CST 2010


Author: tilghman
Date: Wed Feb  3 12:34:29 2010
New Revision: 244505

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=244505
Log:
The chanvar= setting should inherit the entire list of variables, not just the first one.

(closes issue #16359)
 Reported by: raarts
 Patches: 
       dahdi-setvars.diff uploaded by raarts (license 937)
 Tested by: raarts

Modified:
    trunk/channels/chan_dahdi.c

Modified: trunk/channels/chan_dahdi.c
URL: http://svnview.digium.com/svn/asterisk/trunk/channels/chan_dahdi.c?view=diff&rev=244505&r1=244504&r2=244505
==============================================================================
--- trunk/channels/chan_dahdi.c (original)
+++ trunk/channels/chan_dahdi.c Wed Feb  3 12:34:29 2010
@@ -11623,7 +11623,13 @@
 		tmp->callgroup = conf->chan.callgroup;
 		tmp->pickupgroup= conf->chan.pickupgroup;
 		if (conf->chan.vars) {
-			tmp->vars = ast_variable_new(conf->chan.vars->name, conf->chan.vars->value, "");
+			struct ast_variable *v, *tmpvar;
+	                for (v = conf->chan.vars ; v ; v = v->next) {
+        	                if ((tmpvar = ast_variable_new(v->name, v->value, v->file))) {
+                	                tmpvar->next = tmp->vars;
+                        	        tmp->vars = tmpvar;
+                        	}
+                	}
 		}
 		tmp->cid_rxgain = conf->chan.cid_rxgain;
 		tmp->rxgain = conf->chan.rxgain;




More information about the svn-commits mailing list