don't ignore left-curly-braces when searching for the end of a variable/function...
authorKevin P. Fleming <kpfleming@digium.com>
Tue, 18 Apr 2006 23:24:02 +0000 (23:24 +0000)
committerKevin P. Fleming <kpfleming@digium.com>
Tue, 18 Apr 2006 23:24:02 +0000 (23:24 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21235 65c4cc65-6c06-0410-ace0-fbb531ad65f3

pbx.c

diff --git a/pbx.c b/pbx.c
index b66effc..85d692d 100644 (file)
--- a/pbx.c
+++ b/pbx.c
@@ -1343,10 +1343,12 @@ static void pbx_substitute_variables_helper_full(struct ast_channel *c, struct v
                        needsub = 0;
 
                        /* Find the end of it */
-                       while(brackets && *vare) {
+                       while (brackets && *vare) {
                                if ((vare[0] == '$') && (vare[1] == '{')) {
                                        needsub++;
                                        brackets++;
+                               } else if (vare[0] == '{') {
+                                       brackets++;
                                } else if (vare[0] == '}') {
                                        brackets--;
                                } else if ((vare[0] == '$') && (vare[1] == '['))