<p>Friendly Automation <strong>merged</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/11320">View Change</a></p><div style="white-space:pre-wrap">Approvals:
  Joshua Colp: Looks good to me, but someone else must approve
  Kevin Harwell: Looks good to me, approved
  Friendly Automation: Approved for Submit

</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">stasis: Only place stasis created and dialed channels into dial bridge.<br><br>The dial bridge is meant to hold channels which have been created<br>and dialed in stasis. It handles the frames coming from them and raises<br>the appropriate events.<br><br>It was possible for the code to mistakenly place calls which came<br>from the dialplan into the dial bridge if they were not in an<br>answered state. These channels are not outgoing channels and<br>should not be placed into the dial bridge.<br><br>The code now checks to ensure that only stasis created channels are<br>placed into the dial bridge by checking that a PBX does not exist<br>on the channel.<br><br>ASTERISK-27756<br><br>Change-Id: Ideee69ff06c9a0b31f7ed61165f5c055f51d21b6<br>---<br>M res/stasis/control.c<br>1 file changed, 5 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/res/stasis/control.c b/res/stasis/control.c</span><br><span>index 866b58e..3532324 100644</span><br><span>--- a/res/stasis/control.c</span><br><span>+++ b/res/stasis/control.c</span><br><span>@@ -1085,7 +1085,11 @@</span><br><span> {</span><br><span>   ast_bridge_depart(chan);</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-    if (!ast_check_hangup(chan) && ast_channel_state(chan) != AST_STATE_UP) {</span><br><span style="color: hsl(120, 100%, 40%);">+     /* Channels which have a PBX are not ones that have been created and dialed from ARI. They</span><br><span style="color: hsl(120, 100%, 40%);">+     * have externally come in from the dialplan, and thus should not be placed into the dial</span><br><span style="color: hsl(120, 100%, 40%);">+      * bridge. Only channels which are created and dialed in ARI should go into the dial bridge.</span><br><span style="color: hsl(120, 100%, 40%);">+   */</span><br><span style="color: hsl(120, 100%, 40%);">+   if (!ast_check_hangup(chan) && ast_channel_state(chan) != AST_STATE_UP && !ast_channel_pbx(chan)) {</span><br><span>          /* Channel is still being dialed, so put it back in the dialing bridge */</span><br><span>            add_to_dial_bridge(control, chan);</span><br><span>   }</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/11320">change 11320</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/+/11320"/><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: Ideee69ff06c9a0b31f7ed61165f5c055f51d21b6 </div>
<div style="display:none"> Gerrit-Change-Number: 11320 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: Abhay Gupta <abhay@avissol.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: Holger Hans Peter Freyther <automatic@freyther.de> </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>