Make HANGUPCAUSE accessible

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@1669 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Mark Spencer
2003-10-25 18:00:00 +00:00
parent a40f00bee9
commit bc7b8ef41e
3 changed files with 11 additions and 1 deletions

3
pbx.c
View File

@@ -862,6 +862,9 @@ static void pbx_substitute_variables_temp(struct ast_channel *c,const char *var,
} else if (c && !strcmp(var, "UNIQUEID")) {
snprintf(workspace, workspacelen -1, "%s", c->uniqueid);
*ret = workspace;
} else if (c && !strcmp(var, "HANGUPCAUSE")) {
snprintf(workspace, workspacelen -1, "%i", c->hangupcause);
*ret = workspace;
} else {
if (c) {
AST_LIST_TRAVERSE(headp,variables,entries) {