mirror of
https://github.com/PentHertz/OpenBTS.git
synced 2026-05-11 04:43:43 +00:00
Bug #173-public. Now appropriately responds to a SIP CANCEL with a SIP OK. Still won't respond if that OK is dropped.
git-svn-id: http://wush.net/svn/range/software/public/openbts/trunk@2995 19bc5d8c-e614-43d4-8b26-e1612bc8e597
This commit is contained in:
parent
8ba4a6a7ae
commit
a2fa801062
3 changed files with 13 additions and 8 deletions
|
|
@ -679,7 +679,7 @@ SIPState SIPEngine::MTCSendOK( short wRTPPort, unsigned wCodec )
|
|||
mCodec = wCodec;
|
||||
LOG(DEBUG) << "port=" << wRTPPort << " codec=" << mCodec;
|
||||
// Form ack from invite and new parameters.
|
||||
osip_message_t * okay = sip_okay(mINVITE, mSIPUsername.c_str(),
|
||||
osip_message_t * okay = sip_okay_sdp(mINVITE, mSIPUsername.c_str(),
|
||||
mSIPIP.c_str(), mSIPPort, mRTPPort, mCodec);
|
||||
gSIPInterface.write(&mProxyAddr,okay);
|
||||
osip_message_free(okay);
|
||||
|
|
@ -732,8 +732,10 @@ SIPState SIPEngine::MTCWaitForACK()
|
|||
// check for the CANCEL
|
||||
else if( strcmp(ack->sip_method,"CANCEL") == 0){
|
||||
LOG(INFO) << "received CANCEL";
|
||||
osip_message_t * okay = sip_okay(msg, mSIPUsername.c_str(),mSIPIP.c_str(), mSIPPort);
|
||||
gSIPInterface.write(&mProxyAddr,okay);
|
||||
osip_message_free(okay);
|
||||
mState=Fail;
|
||||
// FIXME -- Send 200 OK, see ticket #173.
|
||||
}
|
||||
// check for strays
|
||||
else {
|
||||
|
|
@ -784,6 +786,9 @@ SIPState SIPEngine::MTCCheckForCancel()
|
|||
// check for the CANCEL
|
||||
else if (strcmp(msg->sip_method,"CANCEL")==0) {
|
||||
LOG(INFO) << "received CANCEL";
|
||||
osip_message_t * okay = sip_okay(msg, mSIPUsername.c_str(),mSIPIP.c_str(), mSIPPort);
|
||||
gSIPInterface.write(&mProxyAddr,okay);
|
||||
osip_message_free(okay);
|
||||
mState=Fail;
|
||||
}
|
||||
// check for strays
|
||||
|
|
@ -982,7 +987,7 @@ SIPState SIPEngine::MTSMSSendOK()
|
|||
return mState;
|
||||
}
|
||||
// Form ack from invite and new parameters.
|
||||
osip_message_t * okay = sip_okay_SMS(mINVITE, mSIPUsername.c_str(),
|
||||
osip_message_t * okay = sip_okay(mINVITE, mSIPUsername.c_str(),
|
||||
mSIPIP.c_str(), mSIPPort);
|
||||
gSIPInterface.write(&mProxyAddr,okay);
|
||||
osip_message_free(okay);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue