Ejemplo n.º 1
0
        /// <exception cref="System.IO.IOException"></exception>
        protected internal override void DoDisconnect(bool hard)
        {
            try
            {
                if (Sessions != null)
                {
                    foreach (var ssn in Sessions)
                    {
                        ssn?.Logoff(hard);
                    }
                }

                Out?.Close();
                In?.Close();

                //Socket.`Close` method deleted
                //Socket.Close();
                Socket?.Shutdown(SocketShutdown.Both);
                Socket?.Dispose();
            }
            finally
            {
                Digest       = null;
                Socket       = null;
                TconHostName = null;
            }
        }
Ejemplo n.º 2
0
 protected override void Shutdown()
 {
     _socket.Shutdown(SocketShutdown.Both);
 }