<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">sofia is doing the right thing.. sendrecv is the default state if not otherwise stated in the packet and is not necessary to send there.  the receiving device is broken if its not taking off hold there.<div class=""><br class=""><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Jul 24, 2017, at 5:18 AM, Dmitriy Borisov <<a href="mailto:borik.internet@gmail.com" class="">borik.internet@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><div class=""><div class="">Hello!<br class=""><br class=""></div>There are some issue (or not???) in mod_sofia module.<br class=""><br class=""></div>You can reproduce this issue by holding call via 0.0.0.0 SDP:<br class=""><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">v=0 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">o=OneXS 99765105 2 IN IP4 87.237.24.14 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">s=- </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">c=IN IP4 0.0.0.0 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">t=0 0 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">m=audio 49760 RTP/AVP 8 101 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=fmtp:101 0-15 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=rtpmap:101 telephone-event/8000 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=inactive </span></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class=""><br class=""></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class="">and unholding via invite without SDP. <br class=""></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class=""><br class=""></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class="">In version 7a77e0b (branch v1.6) place of errorneus (as I think) code is near:</div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class=""> 7641             if (switch_channel_var_true(channel, "sip_unhold_nosdp")) {<br class=""> 7642                 switch_core_media_gen_local_sdp(session, SDP_TYPE_RESPONSE, NULL, 0, "sendrecv",<br class=""> 7643                                                 zstr(tech_pvt->mparams.local_sdp_str) || !switch_channel_test_flag(channel, CF_PROXY_MODE));<br class=""> 7644             } else {<br class=""> 7645                 switch_core_media_gen_local_sdp(session, SDP_TYPE_RESPONSE, NULL, 0, NULL,<br class=""> 7646                                             zstr(tech_pvt->mparams.local_sdp_str) || !switch_channel_test_flag(channel, CF_PROXY_MODE));<br class=""> 7647             }<br class=""> 7648<br class=""> 7649             if (zstr(tech_pvt->mparams.local_sdp_str)) {<br class=""> 7650                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Cannot find a SDP\n");<br class=""> 7651                 switch_channel_hangup(channel, SWITCH_CAUSE_DESTINATION_OUT_OF_ORDER);<br class=""> 7652             } else {<br class=""> 7653                 if (sofia_use_soa(tech_pvt)) {<br class=""> 7654                 <b class="">switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, tech_pvt->mparams.local_sdp_str); // This is my add</b><br class=""> 7655                     nua_respond(tech_pvt->nh, SIP_200_OK,<br class=""> 7656                                 SIPTAG_CONTACT_STR(tech_pvt->reply_contact),<br class=""> 7657                                 SOATAG_USER_SDP_STR(tech_pvt->mparams.local_sdp_str),<br class=""> 7658                                 SOATAG_REUSE_REJECTED(1),<br class=""> 7659                                 SOATAG_AUDIO_AUX("cn telephone-event"),<br class=""> 7660                                 TAG_IF(sofia_test_pflag(profile, PFLAG_DISABLE_100REL), NUTAG_INCLUDE_EXTRA_SDP(1)), TAG_END());<br class=""> 7661                 } else {<br class=""> 7662                     nua_respond(tech_pvt->nh, SIP_200_OK,<br class=""> 7663                                 NUTAG_MEDIA_ENABLE(0),<br class=""> 7664                                 SIPTAG_CONTACT_STR(tech_pvt->reply_contact),<br class=""> 7665                                 SIPTAG_CONTENT_TYPE_STR("application/sdp"), SIPTAG_PAYLOAD_STR(tech_pvt->mparams.local_sdp_str), TAG_END());<br class=""> 7666                 }<br class=""> 7667             }<br class=""><br class=""><br class=""></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class="">In described situation code flow go throw line 7654 and post to nua_respond correct SDP (with correct c=IN IP4 re.al.ip.addr and a=sendrecv):</div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class="">2017-07-24 11:00:54.252668 [WARNING] sofia.c:7654 v=0<br class="">o=Sipean 1500875192 1500875195 IN IP4 x.x.x.x:<br class="">s=Sipean<br class="">c=IN IP4 x.x.x.x<br class="">t=0 0<br class="">m=audio 11642 RTP/AVP 8 101<br class="">a=rtpmap:8 PCMA/8000<br class="">a=rtpmap:101 telephone-event/8000<br class="">a=fmtp:101 0-16<br class="">a=ptime:20<br class="">a=sendrecv<br class=""></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class=""><br class=""></div><div style="margin: 0px; text-indent: 0px; font-family: Consolas; font-size: 10pt;" class="">sofia library sends SDP:</div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">v=0 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">o=Sipean 1500875192 1500875195 IN IP4 x.x.x.x </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">s=Sipean </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">c=IN IP4 x.x.x.x </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">t=0 0 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">m=audio 11642 RTP/AVP 8 101 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=rtpmap:8 PCMA/8000 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=rtpmap:101 telephone-event/8000 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=fmtp:101 0-16 </span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">a=ptime:20 <br class=""></span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class=""><br class=""></span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">On SIP client side call in unholded state, but at FreeSWITCH side it is still in HOLDED state<br class=""></span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class=""><br class=""></span></div><div style="margin: 0px; text-indent: 0px;" class=""><span style="font-family:"Consolas";font-size:10pt" class="">I have experimented with nua_respond, but maximum result is a correct call state on SIP client side (holded), but not unholding the line. Where should I search for errors? Or this scenario can't work correct?<br class=""></span></div></div></div></blockquote></div><br class=""></div></div></body></html>