[reSIProcate] why not mCurrentRemoteSdp
Scott Godin
slgodin at icescape.com
Mon Nov 14 05:57:55 CST 2005
The SDP is considered Proposed, until you send your answer, then it becomes mLocalRemoteSdp.
You can access the proposed SDP from the onNewSession callback - it is the 2nd parameter.
-----Original Message-----
From: resiprocate-devel-bounces at list.sipfoundry.org [mailto:resiprocate-devel-bounces at list.sipfoundry.org] On Behalf Of maodonghu
Sent: Monday, November 14, 2005 1:12 AM
To: resiprocate-devel
Subject: [reSIProcate] why not mCurrentRemoteSdp
this is my code to send 200 ok:
call->is->provideAnswer( call->is->getRemoteSdp() );
((ServerInviteSession*)call->is)->accept();
when I track call->is->getRemoteSdp() , I found mCurrentRemoteSdp.get() is NULL, and I have look at ServerInviteSession.cxx(584): it save mProposedRemoteSdp but not mCurrentRemoteSdp, why?
void
ServerInviteSession::dispatchStart(const SipMessage& msg)
{
assert(msg.isRequest());
assert(msg.header(h_CSeq).method() == INVITE);
InviteSessionHandler* handler = mDum.mInviteSessionHandler;
std::auto_ptr<SdpContents> sdp = InviteSession::getSdp(msg);
storePeerCapabilities(msg);
switch (toEvent(msg, sdp.get()))
{
case OnInviteOffer:
mLastSessionModification = msg;
transition(UAS_Offer);
mProposedRemoteSdp = InviteSession::makeSdp(*sdp);
mCurrentEncryptionLevel = getEncryptionLevel(msg);
handler->onNewSession(getHandle(), Offer, msg);
if(!isTerminated())
{
handler->onOffer(getSessionHandle(), msg, *sdp);
}
break;
maodonghu
hhmmdd at tom.com
2005-11-14
More information about the resiprocate-devel
mailing list