Re: [reSIProcate] DialogSetID is not same between onNewSession and onRefer
Thank you, can I just use the CallID hash?
Modify this
size_t DialogSetId::hash() const
{
return mCallId.hash() ^ mTag.hash();
}
to
size_t DialogSetId::hash() const
{
return
mCallId.hash() ;
}
2007/12/20, Byron Campen <bcampen@xxxxxxxxxxxx>:
The INVITE that you get will not have a local-tag (ie; a To-tag) in
it. This is part of the keying info in the DialogSetId. When you
respond to the INVITE, DUM will randomly choose a local-tag (the
remote end needs to choose part of the keying info because of
forking), and this local-tag will come back in the REFER, making the
DialogSetId different. Your best bet is to just use CallId + remote-
tag in this case (hash each, and xor the hashes, since that's what
DialogSetId does anyway).
Best regards,
Byron Campen
> Hi, I want to use the DialogSetID to identifies a Dialog.
>
> When I received a call, I do it:
>
> void UserAgent::onNewSession(ServerInviteSessionHandle h,
> InviteSession::OfferAnswerType oat, const SipMessage & msg)
> {
> DialogSetId inviteID(msg);
> long callID = (long)inviteID.hash();
> }
>
> After I answered this call, the remote side send a REFER to me:
>
> void UserAgent::onRefer(InviteSessionHandle h,
> ServerSubscriptionHandle ssh, const SipMessage& msg)
> {
> DialogSetId inviteID(msg);
> long callID = (long)inviteID.hash();
> }
>
> but these two callID do not same, the callID of onNewSession !=
> callID of the onRefer, did I missed something?
>
> thanks
> _______________________________________________
> resiprocate-devel mailing list
> resiprocate-devel@xxxxxxxxxxxxxxx
> https://list.resiprocate.org/mailman/listinfo/resiprocate-devel