public void SendRaw(SIPEndPoint localSIPEndPoint, SIPEndPoint destinationEndPoint, byte[] buffer)
{
if (destinationEndPoint != null && destinationEndPoint.Address.Equals(BlackholeAddress))
{
// Ignore packet, it's destined for the blackhole.
return;
}
if (m_sipChannels.Count == 0)
{
throw new ApplicationException("No channels are configured in the SIP transport layer. The data could not be sent.");
}
SIPChannel sendSIPChannel = FindSIPChannel(localSIPEndPoint);
if (sendSIPChannel != null)
{
sendSIPChannel.Send(destinationEndPoint.GetIPEndPoint(), buffer);
}
else
{
logger.Warn("No SIPChannel could be found for " + localSIPEndPoint + " in SIPTransport.SendRaw, sending to " + destinationEndPoint.ToString() + ".");
//logger.Warn(Encoding.UTF8.GetString(buffer));
}
}