예제 #1
0
        void scanner_PortReply(System.Net.IPEndPoint remoteEndPoint, Metro.Scanning.TcpPortState state)
        {
            Counter--;
            ScanResult r = new ScanResult();

            r.RemoteEndPoint = remoteEndPoint;
            r.State          = state;
            Results.Add(r);
            this.Invoke(miv);
        }
예제 #2
0
        void scanner_PortReply(System.Net.IPEndPoint remoteEndPoint, Metro.Scanning.TcpPortState state)
        {
            try
            {
                lock (uiElementsLock) pendingRequests--;
                if (state == Metro.Scanning.TcpPortState.Opened)
                {
                    string protocol = Terminals.Connections.ConnectionManager.GetPortName(remoteEndPoint.Port, true);
                    AddFavorite(remoteEndPoint.Address.ToString(), remoteEndPoint.Address.ToString() + "_" + protocol, remoteEndPoint.Port);
                }

                this.Invoke(miv);
            }
            catch (Exception e) { Terminals.Logging.Log.Info("", e); }
        }