Ejemplo n.º 1
0
        private UvTcpHandle CreateAcceptSocket()
        {
            var socket = new UvTcpHandle(Log);

            try
            {
                socket.Init(_thread.Loop, _thread.QueueCloseHandle);
                socket.NoDelay(true);
            }
            catch
            {
                socket.Dispose();
                throw;
            }

            return(socket);
        }
Ejemplo n.º 2
0
        private UvTcpHandle AcceptTcp()
        {
            var socket = new UvTcpHandle(Log);

            try
            {
                socket.Init(Thread.Loop, Thread.QueueCloseHandle);
                socket.NoDelay(EndPointInformation.NoDelay);
            }
            catch
            {
                socket.Dispose();
                throw;
            }

            return(socket);
        }