diff options
author | kpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-09-07 19:13:00 +0000 |
---|---|---|
committer | kpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-09-07 19:13:00 +0000 |
commit | a21860310e9d59b024eaa4cd22e6d85dd8845941 (patch) | |
tree | 09d54e0b28af50c87bac02b87c93c36feb721cf9 /apps/app_disa.c | |
parent | ceace6fb1143f67f0b266c66e63f391840e0e89d (diff) |
convert a bunch of apps to use ast_goto_if_exists() (issue #5138)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6533 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_disa.c')
-rwxr-xr-x | apps/app_disa.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/apps/app_disa.c b/apps/app_disa.c index 9f6977629..47ef714bd 100755 --- a/apps/app_disa.c +++ b/apps/app_disa.c @@ -318,7 +318,7 @@ static int disa_exec(struct ast_channel *chan, void *data) } } - if (k==3 && ast_exists_extension(chan,ourcontext,exten,1, chan->cid.cid_num)) + if (k==3 && ast_exists_extension(chan, ourcontext, exten, 1, chan->cid.cid_num)) { ast_playtones_stop(chan); /* We're authenticated and have a valid extension */ @@ -327,13 +327,12 @@ static int disa_exec(struct ast_channel *chan, void *data) ast_callerid_split(ourcallerid, ourcidname, sizeof(ourcidname), ourcidnum, sizeof(ourcidnum)); ast_set_callerid(chan, ourcidnum, ourcidname, ourcidnum); } - strncpy(chan->exten, exten, sizeof(chan->exten) - 1); - strncpy(chan->context, ourcontext, sizeof(chan->context) - 1); + if (!ast_strlen_zero(acctcode)) { strncpy(chan->accountcode, acctcode, sizeof(chan->accountcode) - 1); } - chan->priority = 0; - ast_cdr_reset(chan->cdr,AST_CDR_FLAG_POSTED); + ast_cdr_reset(chan->cdr, AST_CDR_FLAG_POSTED); + ast_goto_if_exists(chan, ourcontext, exten, 1); LOCAL_USER_REMOVE(u); return 0; } |