[asterisk-commits] rmudgett: branch 12 r397977 - /branches/12/main/pbx.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Aug 29 20:19:28 CDT 2013


Author: rmudgett
Date: Thu Aug 29 20:19:26 2013
New Revision: 397977

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=397977
Log:
pbx.c: Make pbx_substitute_variables_helper_full() not mask variables.

Modified:
    branches/12/main/pbx.c

Modified: branches/12/main/pbx.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/main/pbx.c?view=diff&rev=397977&r1=397976&r2=397977
==============================================================================
--- branches/12/main/pbx.c (original)
+++ branches/12/main/pbx.c Thu Aug 29 20:19:26 2013
@@ -4479,11 +4479,12 @@
 
 			/* Substitute if necessary */
 			if (needsub) {
-				size_t used;
-				if (!ltmp)
+				size_t my_used;
+
+				if (!ltmp) {
 					ltmp = ast_alloca(VAR_BUF_SIZE);
-
-				pbx_substitute_variables_helper_full(c, headp, var, ltmp, VAR_BUF_SIZE - 1, &used);
+				}
+				pbx_substitute_variables_helper_full(c, headp, var, ltmp, VAR_BUF_SIZE - 1, &my_used);
 				vars = ltmp;
 			} else {
 				vars = var;
@@ -4568,11 +4569,12 @@
 
 			/* Substitute if necessary */
 			if (needsub) {
-				size_t used;
-				if (!ltmp)
+				size_t my_used;
+
+				if (!ltmp) {
 					ltmp = ast_alloca(VAR_BUF_SIZE);
-
-				pbx_substitute_variables_helper_full(c, headp, var, ltmp, VAR_BUF_SIZE - 1, &used);
+				}
+				pbx_substitute_variables_helper_full(c, headp, var, ltmp, VAR_BUF_SIZE - 1, &my_used);
 				vars = ltmp;
 			} else {
 				vars = var;




More information about the asterisk-commits mailing list