Merged revisions 59486 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r59486 | murf | 2007-03-30 08:11:59 -0600 (Fri, 30 Mar 2007) | 1 line

These mods fix CDR issues from 8221, 8593, 8680, 8743, and perhaps others. Mainly with CDRs generated from transfer situations.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@59500 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Steve Murphy
2007-03-30 14:37:21 +00:00
parent 684527fcfd
commit 0f11d3c8c3
5 changed files with 273 additions and 2 deletions

View File

@@ -4574,6 +4574,9 @@ int ast_async_goto(struct ast_channel *chan, const char *context, const char *ex
the PBX, we have to make a new channel, masquerade, and start the PBX
at the new location */
struct ast_channel *tmpchan = ast_channel_alloc(0, chan->_state, 0, 0, "AsyncGoto/%s", chan->name);
if (chan->cdr) {
tmpchan->cdr = ast_cdr_dup(chan->cdr);
}
if (!tmpchan)
res = -1;
else {
@@ -4936,7 +4939,10 @@ static int ast_pbx_outgoing_cdr_failed(void)
if (!chan)
return -1; /* failure */
chan->cdr = ast_cdr_alloc(); /* allocate a cdr for the channel */
if (!chan->cdr) {
chan->cdr = ast_cdr_alloc(); /* allocate a cdr for the channel */
ast_log(LOG_NOTICE, "=====PBX_OUTGOING_CDR_FAILED ALLOCS CHANNEL CDR for %s\n", chan->name);
}
if (!chan->cdr) {
/* allocation of the cdr failed */