mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-05 04:11:08 +00:00
ensure account code is not overwritten when none is supplied (bug #4743)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6168 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -329,7 +329,9 @@ static int disa_exec(struct ast_channel *chan, void *data)
|
|||||||
}
|
}
|
||||||
strncpy(chan->exten, exten, sizeof(chan->exten) - 1);
|
strncpy(chan->exten, exten, sizeof(chan->exten) - 1);
|
||||||
strncpy(chan->context, ourcontext, sizeof(chan->context) - 1);
|
strncpy(chan->context, ourcontext, sizeof(chan->context) - 1);
|
||||||
strncpy(chan->accountcode, acctcode, sizeof(chan->accountcode) - 1);
|
if (!ast_strlen_zero(acctcode)) {
|
||||||
|
strncpy(chan->accountcode, acctcode, sizeof(chan->accountcode) - 1);
|
||||||
|
}
|
||||||
chan->priority = 0;
|
chan->priority = 0;
|
||||||
ast_cdr_reset(chan->cdr,AST_CDR_FLAG_POSTED);
|
ast_cdr_reset(chan->cdr,AST_CDR_FLAG_POSTED);
|
||||||
LOCAL_USER_REMOVE(u);
|
LOCAL_USER_REMOVE(u);
|
||||||
|
Reference in New Issue
Block a user