summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorMark Michelson <mmichelson@digium.com>2008-07-09 19:40:30 +0000
committerMark Michelson <mmichelson@digium.com>2008-07-09 19:40:30 +0000
commitcd16dca4599df49b56617762d2258fa8f0838d91 (patch)
tree05ed14215ec75783596f1d07a12ab9f55765a288 /main
parent0b185a22761a17fb13f8fbd5d1367230ef82076c (diff)
Merged revisions 129436 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r129436 | mmichelson | 2008-07-09 14:32:20 -0500 (Wed, 09 Jul 2008) | 13 lines Fix a problem where inbound rfc2833 audio would be sent to the core instead of being P2P bridged. When the core regenerated the rfc2833 packet for the outbound leg, the SSRC would be different than the RTP audio on the call leg causing DTMF detection issues on the far end. (closes issue #12955) Reported by: tonyredstone Patches: dynamic_rtp.patch uploaded by tsearle (license 373) Tested by: tonyredstone ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@129437 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main')
-rw-r--r--main/rtp.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/main/rtp.c b/main/rtp.c
index 1370e12d2..bc3db9b4b 100644
--- a/main/rtp.c
+++ b/main/rtp.c
@@ -1479,10 +1479,6 @@ static int bridge_p2p_rtp_write(struct ast_rtp *rtp, struct ast_rtp *bridged, un
/* Check what the payload value should be */
rtpPT = ast_rtp_lookup_pt(rtp, payload);
- /* If the payload coming in is not one of the negotiated ones then send it to the core, this will cause formats to change and the bridge to break */
- if (!bridged->current_RTP_PT[payload].code)
- return -1;
-
/* If the payload is DTMF, and we are listening for DTMF - then feed it into the core */
if (ast_test_flag(rtp, FLAG_P2P_NEED_DTMF) && !rtpPT.isAstFormat && rtpPT.code == AST_RTP_DTMF)
return -1;
@@ -1490,6 +1486,11 @@ static int bridge_p2p_rtp_write(struct ast_rtp *rtp, struct ast_rtp *bridged, un
/* Otherwise adjust bridged payload to match */
bridged_payload = ast_rtp_lookup_code(bridged, rtpPT.isAstFormat, rtpPT.code);
+ /* If the payload coming in is not one of the negotiated ones then send it to the core, this will cause formats to change and the bridge to break */
+ if (!bridged->current_RTP_PT[bridged_payload].code)
+ return -1;
+
+
/* If the mark bit has not been sent yet... do it now */
if (!ast_test_flag(rtp, FLAG_P2P_SENT_MARK)) {
mark = 1;