aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authormurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2006-08-15 22:13:47 +0000
committermurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2006-08-15 22:13:47 +0000
commit0e410ba417475d2d3b59bc6cc8b8e93f58b2ec70 (patch)
treefeb1808bdf734e9fd1eee3ba80f8c2a89e8cc763 /apps
parentf50533d4e2b3f8af8ba8fbf4058f1062b6a27215 (diff)
This revision fixes bug 7731, the inability for macros to be called more than one level deep in the 'h' extension.
It also pushes up the limit of recursion depth from 7 to 20. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2@39931 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r--apps/app_macro.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/app_macro.c b/apps/app_macro.c
index 745bf4e36..4fb336025 100644
--- a/apps/app_macro.c
+++ b/apps/app_macro.c
@@ -127,7 +127,7 @@ static int macro_exec(struct ast_channel *chan, void *data)
depth = 0;
}
- if (depth >= 7) {
+ if (depth >= 20) {
ast_log(LOG_ERROR, "Macro(): possible infinite loop detected. Returning early.\n");
LOCAL_USER_REMOVE(u);
return 0;
@@ -241,9 +241,9 @@ static int macro_exec(struct ast_channel *chan, void *data)
break;
}
/* don't stop executing extensions when we're in "h" */
- if (chan->_softhangup && strcasecmp(oldexten,"h")) {
- ast_log(LOG_DEBUG, "Extension %s, priority %d returned normally even though call was hung up\n",
- chan->exten, chan->priority);
+ if (chan->_softhangup && strcasecmp(chan->macroexten,"h")) {
+ ast_log(LOG_DEBUG, "Extension %s, macroexten %s, priority %d returned normally even though call was hung up\n",
+ chan->exten, chan->macroexten, chan->priority);
goto out;
}
chan->priority++;