internal void Close()
{
if (_log.IsLoggable(EventLogEntryType.Information))
_log.Info("Close {0}", this);
Trace.TraceInformation("Close '{0}'", this);
lock (this) {
_idleHead = _idleTail = 0;
}
for (int i = 0; i < _idle.Length; i++) {
HmuxConnection channel;
lock (this) {
channel = _idle[i];
_idle[i] = null;
}
if (channel != null)
channel.CloseImpl();
}
}