<p>Joshua Colp <strong>submitted</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/13311">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Joshua Colp: Looks good to me, but someone else must approve; Approved for Submit
Benjamin Keith Ford: Looks good to me, but someone else must approve
Kevin Harwell: Looks good to me, approved
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">chan_sip+native_bridge_rtp: no directmedia for ptime other than default ptime.<br><br>During capabilities selection (joint capabilities of us and peer,<br>configured capability for this peer, or general configured<br>capabilities), if sip_new() does not keep framing information,<br>then directmedia activation will fail for any framing different<br>from default framing.<br><br>ASTERISK-28637<br><br>Change-Id: I99257502788653c2816fc991cac7946453082466<br>---<br>M bridges/bridge_native_rtp.c<br>M channels/chan_sip.c<br>2 files changed, 9 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/bridges/bridge_native_rtp.c b/bridges/bridge_native_rtp.c</span><br><span>index 602fed8..7fd4ae1 100644</span><br><span>--- a/bridges/bridge_native_rtp.c</span><br><span>+++ b/bridges/bridge_native_rtp.c</span><br><span>@@ -713,6 +713,8 @@</span><br><span> framing_inst0, framing_inst1);</span><br><span> return 0;</span><br><span> }</span><br><span style="color: hsl(120, 100%, 40%);">+ ast_debug(3, "Symmetric ptimes on the two call legs (%u). May be able to native bridge in RTP\n",</span><br><span style="color: hsl(120, 100%, 40%);">+ framing_inst0);</span><br><span> }</span><br><span> </span><br><span> read_ptime0 = ast_format_cap_get_format_framing(cap0, ast_channel_rawreadformat(bc0->chan));</span><br><span>@@ -726,6 +728,9 @@</span><br><span> read_ptime0, write_ptime1, read_ptime1, write_ptime0);</span><br><span> return 0;</span><br><span> }</span><br><span style="color: hsl(120, 100%, 40%);">+ ast_debug(3, "Bridge '%s': Packetization comparison success between RTP streams (read_ptime0:%d == write_ptime1:%d and read_ptime1:%d == write_ptime0:%d).\n",</span><br><span style="color: hsl(120, 100%, 40%);">+ bridge->uniqueid,</span><br><span style="color: hsl(120, 100%, 40%);">+ read_ptime0, write_ptime1, read_ptime1, write_ptime0);</span><br><span> </span><br><span> return 1;</span><br><span> }</span><br><span>diff --git a/channels/chan_sip.c b/channels/chan_sip.c</span><br><span>index 4d79a47..bb56028 100644</span><br><span>--- a/channels/chan_sip.c</span><br><span>+++ b/channels/chan_sip.c</span><br><span>@@ -8193,8 +8193,11 @@</span><br><span> /* Use only the preferred audio format, which is stored at the '0' index */</span><br><span> fmt = ast_format_cap_get_best_by_type(what, AST_MEDIA_TYPE_AUDIO); /* get the best audio format */</span><br><span> if (fmt) {</span><br><span style="color: hsl(120, 100%, 40%);">+ int framing;</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> ast_format_cap_remove_by_type(caps, AST_MEDIA_TYPE_AUDIO); /* remove only the other audio formats */</span><br><span style="color: hsl(0, 100%, 40%);">- ast_format_cap_append(caps, fmt, 0); /* add our best choice back */</span><br><span style="color: hsl(120, 100%, 40%);">+ framing = ast_format_cap_get_format_framing(what, fmt);</span><br><span style="color: hsl(120, 100%, 40%);">+ ast_format_cap_append(caps, fmt, framing); /* add our best choice back */</span><br><span> } else {</span><br><span> /* If we don't have an audio format, try to get something */</span><br><span> fmt = ast_format_cap_get_format(caps, 0);</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/13311">change 13311</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/c/asterisk/+/13311"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 16 </div>
<div style="display:none"> Gerrit-Change-Id: I99257502788653c2816fc991cac7946453082466 </div>
<div style="display:none"> Gerrit-Change-Number: 13311 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Frederic LE FOLL <frederic.lefoll@c-s.fr> </div>
<div style="display:none"> Gerrit-Reviewer: Benjamin Keith Ford <bford@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Kevin Harwell <kharwell@digium.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>