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

Re: [reSIProcate] PRACK UAS support


Hi Martin,
We discovered a bug the other day, so here is a patch for the patch.

Best Regards
Björn 
--- ServerInviteSession.cxx.orig	2009-10-23 10:14:56.000000000 +0200
+++ ServerInviteSession.cxx	2009-10-23 10:16:25.000000000 +0200
@@ -342,51 +342,51 @@
 void 
 ServerInviteSession::provideAnswer(const SdpContents& answer)
 {
    InviteSessionHandler* handler = mDum.mInviteSessionHandler;
    InfoLog (<< toData(mState) << ": provideAnswer");
    mAnswerSentReliably = false;
    switch (mState)
    {
       case UAS_Offer:
          transition(UAS_OfferProvidedAnswer);
          mCurrentRemoteSdp = mProposedRemoteSdp;
          mCurrentLocalSdp = InviteSession::makeSdp(answer);
          break;
 
       case UAS_EarlyOffer:
          transition(UAS_EarlyProvidedAnswer);
          mCurrentRemoteSdp = mProposedRemoteSdp;
          mCurrentLocalSdp = InviteSession::makeSdp(answer);
          break;
          
       case UAS_ReceivedOfferReliable: 
       case UAS_FirstNoAnswerReliable: 
          // send1XX-answer, timer::1xx
          mCurrentRemoteSdp = mProposedRemoteSdp;
          mCurrentLocalSdp = InviteSession::makeSdp(answer);
-         transition(UAS_FirstSentAnswerReliable);
+         transition(UAS_ReceivedOfferReliableProvidedAnswer);
          break;
 
       case UAS_ReceivedUpdate:
          // send::200U-answer
          transition(UAS_NegotiatedReliable);
          break;
          
       case UAS_ReceivedUpdateWaitingAnswer:
          // send::2XXU-answer
          // send::2XXI
          transition(Connected);
          handler->onConnected(getSessionHandle(), *mInvite200);
          break;
 
       case UAS_NoAnswerReliable:
          mCurrentRemoteSdp = mProposedRemoteSdp;
          mCurrentLocalSdp = InviteSession::makeSdp(answer);
          break;
 
       case UAS_NegotiatedReliable:
          mCurrentRemoteSdp = mProposedRemoteSdp;
          mCurrentLocalSdp = InviteSession::makeSdp(answer);
          if(mPrackWithOffer.get())
          {
             SharedPtr<SipMessage> p200(new SipMessage);