<div dir="ltr"><div dir="ltr">On Sun, Dec 13, 2020 at 1:57 AM Ahmed Fouad <<a href="mailto:afouad@gmail.com">afouad@gmail.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Hi,</div><div><br></div><div>I've a situation with remote attended transfer and like to solve it by putting the 2nd channel in the bridge in UNHOLD state when swapping is completed.</div><div>I started debugging the code with res_pjsip_refer.c: INVITE with Replaces being attempted.</div><div><br></div><div>I'm running Asterisk certified/16.8-cert3</div><div><br></div><div>[Dec 12 12:03:20] DEBUG[10736] res_pjsip_refer.c: INVITE with Replaces being attempted.  'PJSIP/XXXX-00000011' --> 'PJSIP/XXXX-0000000e'<br>[Dec 12 12:03:20] DEBUG[14235] bridge_channel.c: Bridge 883a1d4a-580d-470d-8448-90b2a03b637b: 0x7f305403c998(PJSIP/XXXX-00000011) is joining<br>[Dec 12 12:03:20] DEBUG[14235] bridge_channel.c: Bridge 883a1d4a-580d-470d-8448-90b2a03b637b: pushing 0x7f305403c998(PJSIP/XXXX-00000011) by swapping with 0x7f305408bea8(PJSIP/XXXX-0000000e)<br>[Dec 12 12:03:20] DEBUG[14235] bridge_channel.c: Setting 0x7f305408bea8(PJSIP/XXXX-0000000e) state from:0 to:2<br>[Dec 12 12:03:20] DEBUG[14235] bridge_channel.c: Bridge 883a1d4a-580d-470d-8448-90b2a03b637b: pulling 0x7f305408bea8(PJSIP/XXXX-0000000e)<br>[Dec 12 12:03:20] VERBOSE[14235] bridge_channel.c: Channel PJSIP/XXXX-0000000e left 'simple_bridge' basic-bridge <883a1d4a-580d-470d-8448-90b2a03b637b><br>[Dec 12 12:03:20] DEBUG[14235] bridge_channel.c: Bridge 883a1d4a-580d-470d-8448-90b2a03b637b: 0x7f305408bea8(PJSIP/XXXX-0000000e) is leaving simple_bridge technology<br>[Dec 12 12:03:20] VERBOSE[14235] bridge_channel.c: Channel PJSIP/XXXX-00000011 swapped with PJSIP/XXXX-0000000e into 'simple_bridge' basic-bridge <883a1d4a-580d-470d-8448-90b2a03b637b><br>[Dec 12 12:03:20] DEBUG[14235] bridge_native_rtp.c: Bridge '883a1d4a-580d-470d-8448-90b2a03b637b'.  Checking compatability for channels '<b>PJSIP/pstn-0000000f</b>' and 'PJSIP/XXXX-00000011'</div><div><br></div><div>In this step I'd like to make sure that the other channel 
<b>PJSIP/pstn-0000000f</b> in the bridge is off hold or put it off-hold.</div><div><br></div><div>How can I accomplish it <br>?</div></div></blockquote><div><br></div><div>I believe such things should already happen[1], but if I recall you posted on the community forum about other code modifications[2]. Have you done changes in the SDP side? Otherwise you'd need to show exactly what is happening.</div></div><div><br></div><div>[1] <a href="https://github.com/asterisk/asterisk/blob/certified/16.8/main/bridge.c#L4779">https://github.com/asterisk/asterisk/blob/certified/16.8/main/bridge.c#L4779</a></div><div>[2] <a href="https://community.asterisk.org/t/chan-pjsip-add-support-for-passing-hold-and-unhold-requests-through/86738">https://community.asterisk.org/t/chan-pjsip-add-support-for-passing-hold-and-unhold-requests-through/86738</a></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div style="font-family:tahoma,sans-serif"><font color="#073763">Joshua C. Colp</font></div><div style="font-family:tahoma,sans-serif"><font color="#073763">Asterisk Technical Lead</font></div><div style="font-family:tahoma,sans-serif"><font color="#073763">Sangoma Technologies</font></div><div style="font-family:tahoma,sans-serif"><font color="#073763">Check us out at <a href="http://www.sangoma.com" target="_blank">www.sangoma.com</a> and <a href="http://www.asterisk.org" target="_blank">www.asterisk.org</a></font><br></div></div></div></div></div></div></div></div></div></div></div>