<div dir="ltr"><br><div class="gmail_extra">Hi Carsten,</div><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks for your reply!</div><div class="gmail_extra"><br></div><div class="gmail_extra">How can I call msg_apply_changes() in right way? If I call msg_apply_changes() for example in route[RELAY] i get error:</div><div class="gmail_extra">ERROR: textopsx [textopsx.c:157]: msg_apply_changes_f(): invalid usage - not in request route</div><div class="gmail_extra"><br></div><div class="gmail_extra">if I do everything as you suggested in onreply_route (after I get for example SIP 500 message) it doesn't work and my SDP remains unchanged.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks!</div><div class="gmail_extra"><br><div class="gmail_quote"><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><br>
<div><br><blockquote type="cite"><span style="font-family:-webkit-system-font,'Helvetica Neue',Helvetica,sans-serif"><b>From: </b></span><span style="font-family:-webkit-system-font,'Helvetica Neue',Helvetica,sans-serif">Carsten Bock <<a href="mailto:carsten@ng-voice.com" target="_blank">carsten@ng-voice.com</a>></span><br><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px"><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif;color:rgba(0,0,0,1.0)"><b>Subject: </b></span><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif"><b>Re: [SR-Users] rtpengine rewrite sdp for second time</b><br></span></div><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px"><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif;color:rgba(0,0,0,1.0)"><b>Date: </b></span><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif">17 Aug 2015 09:49:12 EEST<br></span></div><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px"><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif;color:rgba(0,0,0,1.0)"><b>To: </b></span><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif">"Kamailio (SER) - Users Mailing List" <<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a>><br></span></div><div style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px"><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif;color:rgba(0,0,0,1.0)"><b>Reply-To: </b></span><span style="font-family:-webkit-system-font,Helvetica Neue,Helvetica,sans-serif">"Kamailio \(SER\) - Users Mailing List" <<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a>><br></span></div><br><div>Hi Virmantas,<br><br>you could try to one or a combination of the following:<br>- explicitly delete the first session by calling rtpengine_manage() in<br>the failure route<br>- call msg_apply_changes() from Textops before calling<br>rtpengine_manage() the second time (so the already made changes are<br>applied and the message gets reparsed)<br><br>Thanks,<br>Carsten<br><br>2015-08-16 20:13 GMT+02:00 Virmantas Variakojis<br><<a href="mailto:virmantas.variakojis@gmail.com" target="_blank">virmantas.variakojis@gmail.com</a>>:<br><blockquote type="cite">Hi,<br><br>I have a situation like this:<br>I have kamailio with 3 NIC's. I'm sending INVITE to first provider over<br>NIC1. Before sending INVITE I use rtpengine_manage to rewrite sdp body with<br>IP that is on NIC1:<br>rtpengine_manage ("replace-origin replace-session-connection<br>direction=intvlan direction=prov1 ICE=remove");<br><br>If first provider fails i want to send INVITE for the same call to second<br>provider. But if i use like this:<br>rtpengine_manage ("replace-origin replace-session-connection<br>direction=intvlan direction=prov2 ICE=remove");<br>or (because ip of prov1 is allready set):<br>rtpengine_manage ("replace-origin replace-session-connection direction=prov1<br>direction=prov2 ICE=remove");<br>rtpengine ignores my changes as said in documentation: "The direction must<br>only be specified in for initial SDP offer; answers or subsequent offers can<br>omit this option."<br><br>and if I try to set ip like this:<br>rtpengine_manage ("replace-origin replace-session-connection<br>media-address=X.X.X.X ICE=remove");<br>SDP body is doubled: it leaves old values and adds the new one.<br><br>What i'm doing wrong or how can I rewrite SDP for second time? Thanks in<br>advance for answer!<br><br>_______________________________________________<br>SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br><a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br><a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br><br></blockquote><br><br><br>-- <br>Carsten Bock<br>CEO (Geschäftsführer)<br><br>ng-voice GmbH<br>Schomburgstr. 80<br>D-22767 Hamburg / Germany<br><br><a href="http://www.ng-voice.com" target="_blank">http://www.ng-voice.com</a><br>mailto:<a href="mailto:carsten@ng-voice.com" target="_blank">carsten@ng-voice.com</a><br><br>Office +49 40 5247593-0<br>Fax <a href="tel:%2B49%2040%205247593-99" value="+4940524759399" target="_blank">+49 40 5247593-99</a><br><br>Sitz der Gesellschaft: Hamburg<br>Registergericht: Amtsgericht Hamburg, HRB 120189<br>Geschäftsführer: Carsten Bock<br>Ust-ID: DE279344284<br><br>Hier finden Sie unsere handelsrechtlichen Pflichtangaben:<br><a href="http://www.ng-voice.com/imprint/" target="_blank">http://www.ng-voice.com/imprint/</a><br><br>_______________________________________________<br>SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br><a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br><a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a></div></blockquote></div></div></blockquote></div><br></div></div>