aboutsummaryrefslogtreecommitdiffstats
path: root/main/features.c
diff options
context:
space:
mode:
authormnicholson <mnicholson@f38db490-d61c-443f-a65b-d21fe96a405b>2009-11-20 21:01:10 +0000
committermnicholson <mnicholson@f38db490-d61c-443f-a65b-d21fe96a405b>2009-11-20 21:01:10 +0000
commit1b44ad796b4efc7a1951bc5fb06fa4136a9ef471 (patch)
treee489e63cf789e19d71abb0e2af8a0363bf3c76e9 /main/features.c
parent01b456e5538276f4b92e36e05c2692531d4e0cd8 (diff)
Merged revisions 230627 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r230627 | mnicholson | 2009-11-20 14:53:06 -0600 (Fri, 20 Nov 2009) | 8 lines Copy the peer CDR's userfield to the bridge CDR if it exists. This is necessary for the recordagentcalls option in chan_agent to store the recorded file name in the bridge CDR. (closes issue #14590) Reported by: msetim Patches: queue_agent_userfield.patch uploaded by Laureano (license 265) Tested by: Laureano, mnicholson ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@230628 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/features.c')
-rw-r--r--main/features.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/main/features.c b/main/features.c
index d062db951..c2430a836 100644
--- a/main/features.c
+++ b/main/features.c
@@ -2807,6 +2807,10 @@ int ast_bridge_call(struct ast_channel *chan,struct ast_channel *peer,struct ast
bridge_cdr = ast_cdr_dup_unique_swap(chan_cdr);
ast_copy_string(bridge_cdr->lastapp, S_OR(chan->appl, ""), sizeof(bridge_cdr->lastapp));
ast_copy_string(bridge_cdr->lastdata, S_OR(chan->data, ""), sizeof(bridge_cdr->lastdata));
+ if (peer_cdr && !ast_strlen_zero(peer_cdr->userfield)) {
+ ast_copy_string(bridge_cdr->userfield, peer_cdr->userfield, sizeof(bridge_cdr->userfield));
+ }
+
} else {
/* better yet, in a xfer situation, find out why the chan cdr got zapped (pun unintentional) */
bridge_cdr = ast_cdr_alloc(); /* this should be really, really rare/impossible? */