SIPSorcery.AppServer.DialPlan.ForkCall.UACCallFailed C# (CSharp) Method

UACCallFailed() private method

This event occurs if it was not possible to initiate a call to the destination specified in the forwarded call. An example would be an unresolvable hostname in the destination URI.
private UACCallFailed ( ISIPClientUserAgent uac, string errorMessage ) : void
uac ISIPClientUserAgent
errorMessage string
return void
        private void UACCallFailed(ISIPClientUserAgent uac, string errorMessage)
        {
            lock (m_switchCalls)
            {
                m_switchCalls.Remove(uac);
            }

            m_lastFailureStatus = SIPResponseStatusCodesEnum.TemporarilyUnavailable;
            m_lastFailureReason = errorMessage;

            if (m_switchCallTransactions != null && uac.ServerTransaction != null)
            {
                m_switchCallTransactions.Add(uac.ServerTransaction);
            }

            uac.CallAnswered -= UACCallAnswered;
            uac.CallFailed -= UACCallFailed;
            uac.CallRinging -= UACCallProgress;

            CallLegCompleted();
        }