Module: sems
Branch: kubartv/error_recovery
Commit: 912807c77b9aa083e5de5f1d93a4b90fd98ffb4a
URL:    
http://git.sip-router.org/cgi-bin/gitweb.cgi/sems/?a=commit;h=912807c77b9aa083e5de5f1d93a4b90fd98ffb4a

Author: Václav Kubart <[email protected]>
Committer: Václav Kubart <[email protected]>
Date:   Mon Mar 10 15:38:27 2014 +0100

sbc b/f: handle rejected offer

---

 apps/sbc/CallLeg.cpp |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/apps/sbc/CallLeg.cpp b/apps/sbc/CallLeg.cpp
index b3e96a5..64e49c6 100644
--- a/apps/sbc/CallLeg.cpp
+++ b/apps/sbc/CallLeg.cpp
@@ -986,6 +986,7 @@ void CallLeg::onSipReply(const AmSipRequest& req, const 
AmSipReply& reply, AmSip
     return;
   }
 #endif
+  if (reply.code >= 300 && reply.cseq_method == SIP_METH_INVITE) 
offerRejected();
 
   AmB2BSession::onSipReply(req, reply, old_dlg_status);
 
@@ -1615,11 +1616,13 @@ void CallLeg::updateLocalSdp(AmSdp &sdp)
 
 void CallLeg::offerRejected()
 {
+  TRACE("%s: offer rejected! (hold status: %d)", getLocalTag().c_str(), hold);
   switch (hold) {
     case HoldRequested: holdRejected(); break;
     case ResumeRequested: resumeRejected(); break;
     case PreserveHoldStatus: break;
   }
+  hold = PreserveHoldStatus;
 }
 
 void CallLeg::createResumeRequest(AmSdp &sdp)

_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev

Reply via email to