< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index Next in Thread >

RE: [reSIProcate] Handling REFERS with Replaces


DUM will not end the other dialog - you must control that.  Here is some
code that will help
if(msg->exits(h_Replaces))
{
   pair<InviteSessionHandle, int> presult;
   presult = dum->findInviteSession(msg->header(h_Replaces));
   if(presult != InviteSessionHandle::NotValid())
   {
      ... // Do stuff in app to swap contexts
        Presult.first->end(); // end original session
   }
}

Scott

PS.  I just added this info to the Wiki: 
http://wiki.resiprocate.org/wiki/index.php?title=Dealing_with_REFERs


> -----Original Message-----
> From: resiprocate-devel-bounces@xxxxxxxxxxxxxxxxxxx
[mailto:resiprocate-
> devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of Anumeet Singh
> Sent: Friday, December 09, 2005 7:54 AM
> To: resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> Subject: [reSIProcate] Handling REFERS with Replaces
> 
> 
> Hi
> 
> I have a very simple scenario.
> I want to send a REFER with the Replaces header. This is really simple
> using
> the refer() method.
> In the UAC receiving the INVITE that is a result of this refer I want
to
> handle the INVITE in a normal manner.
> 
> Do I have to terminate the dialog that is replaced, or is this handled
> automatically?
> If I have to do it myself, where can I get a hold of the Replaces
header,
> or
> at least the original INVITE message from the InviteSession?
> When a dialog is connected I want to check if the original request
> contained
> a Replaces header, use the findInviteSession and finally end the
replaced
> dialog. I would not want to keep the Replaces information saved
somewhere
> during the dialog setup, to be used in a later stage when the dialog
is
> connected.
> 
> Best Regards
> 
> Anumeet
> 
> _______________________________________________
> resiprocate-devel mailing list
> resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> https://list.sipfoundry.org/mailman/listinfo/resiprocate-devel