dect
/
asterisk
Archived
13
0
Fork 0

Don't set a global variable if the channel you're trying to set CHANLOCALSTATUS on has gone away already.

git-svn-id: http://svn.digium.com/svn/asterisk/trunk@9139 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
bweschke 2006-02-03 22:38:38 +00:00
parent d36e97804d
commit 3d8a107846
1 changed files with 1 additions and 1 deletions

View File

@ -394,7 +394,7 @@ static int local_hangup(struct ast_channel *ast)
isoutbound = IS_OUTBOUND(ast, p);
if (isoutbound) {
status = pbx_builtin_getvar_helper(p->chan, "DIALSTATUS");
if(status)
if ((status) && (p->owner))
pbx_builtin_setvar_helper(p->owner, "CHANLOCALSTATUS", status);
p->chan = NULL;
p->launchedpbx = 0;