[reSIProcate] SipStack process CANCEL problem!
fancy_xiao
fancy_xiao at astrocom.cn
Thu May 31 04:17:19 CDT 2007
resiprocate-devel,你好
When TU send an INVITE to external,then TU send CANCEL to external ,but TransationState not received 1xx,
the stack process the CANCEL,and return INVITE 487, delete the ClientTransaction,and ;
The stack don't terminateClientTransaction and create a TransactionTerminated Message to TU!
Is it a bug ?
The source Code in TransactionState.cxx:
TransactionState* matchingInvite = controller.mClientTransactionMap.find(sip->getTransactionId());
if (matchingInvite == 0)
{
InfoLog (<< "No matching INVITE for incoming (from TU) CANCEL to uac");
TransactionState::sendToTU(tu, controller, Helper::makeResponse(*sip,481));
delete sip;
}
else if (matchingInvite->mState == Calling) // CANCEL before 1xx received
{
WarningLog(<< "You can't CANCEL a request until a provisional has been received");
StackLog (<< *matchingInvite);
StackLog (<< *sip);
// if no INVITE had been sent out yet. -- i.e. dns result not
// processed yet
// The CANCEL was received before the INVITE was sent
// This can happen in odd cases. Too common to assert.
// Be graceful.
TransactionState::sendToTU(tu, controller, Helper::makeResponse(*sip, 200));
matchingInvite->sendToTU(Helper::makeResponse(*matchingInvite->mMsgToRetransmit, 487));
delete matchingInvite;
delete sip;
}
fancy_xiao,fancy_xiao at astrocom.cn
2007-05-31
More information about the resiprocate-devel
mailing list