protected void SendChannelOpenMessage()
{
// do not allow open to be ChannelOpenMessage to be sent again until we've
// had a response on the previous attempt for the current channel
if (Interlocked.CompareExchange(ref _sessionSemaphoreObtained, 1, 0) == 0)
{
SessionSemaphore.Wait();
SendMessage(
new ChannelOpenMessage(
LocalChannelNumber,
LocalWindowSize,
LocalPacketSize,
new SessionChannelOpenInfo()));
}
}