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

Re: [reSIProcate-users] A bug of service-route header?


I‘m sorry, it's my mistake.
Thanks


On Wed, Jun 24, 2009 at 12:15 AM, Scott Godin <sgodin@xxxxxxxxxxxxxxx> wrote:
Are you sure you are passing no user profile to either DialogUsageManager::makeRegistration, or DialogUsageManager::makeInviteSession?  It should work if you either pass the same UserProfile (shared_ptr), or pass no user profile either of the API's (so that DUM will default to MasterProfile for both).

Scott

On Tue, Jun 23, 2009 at 8:58 AM, Karlsson <boost.regex@xxxxxxxxx> wrote:
Hi all, maybe this is a bug ?
 
I saw In ClientRegistration.cxx file, the line 392, when the UA received 200 OK of REGISTER message, if the 200 OK has Service-route header,
the DUM will call setServiceRoute(msg.header(h_ServiceRoutes)) to add the Route header for SIP message.
 
     try
         {
            if (msg.exists(h_ServiceRoutes))
            {
               InfoLog(<< "Updating service route: " << Inserter(msg.header(h_ServiceRoutes)));
               getUserProfile()->setServiceRoute(msg.header(h_ServiceRoutes));
            }
            else
            {
               DebugLog(<< "Clearing service route (" << Inserter(getUserProfile()->getServiceRoute()) << ")");
               getUserProfile()->setServiceRoute(NameAddrs());
            }
         }
         catch(BaseException &e)
         {
            InfoLog(<< "Error Parsing Service Route:" << e);
         }   
 
But as my test, when I make call after register succeeded, the INVITE message does not included ROUTE header.
I have to write below code after the register succeeded(I just use single master profile, no user profile):
 
void UserAgent::onSuccess(ClientRegistrationHandle h, const SipMessage& response)
{
  try
  {
   if (response.exists(h_ServiceRoutes))
   {
    mMasterProfile->setServiceRoute(response.header(h_ServiceRoutes));
   }
   else
   {
    mMasterProfile->setServiceRoute(NameAddrs());
   }
  }
  catch(BaseException &e)
  {
  }   
}
 
Then  the INVITE message inlcuded ROUTE header.

 

_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/