void client_onClientDisconnected(object sender, SocksClientEventArgs e) { e.Client.onClientDisconnected -= client_onClientDisconnected; e.Client.Client.onDataReceived -= onDataReceived; e.Client.Client.onDataSent -= onDataSent; this.Clients.Remove(e.Client); }
private void client_onClientDisconnected(object sender, SocksClientEventArgs e) { e.Client.OnClientDisconnected -= client_onClientDisconnected; foreach (ClientDisconnectedHandler cdh in PluginLoader.LoadPlugin(typeof(ClientDisconnectedHandler))) { cdh.OnDisconnected(sender, e); } Clients.Remove(e.Client); }
void client_onClientDisconnected(object sender, SocksClientEventArgs e) { e.Client.onClientDisconnected -= client_onClientDisconnected; e.Client.Client.onDataReceived -= Client_onDataReceived; e.Client.Client.onDataSent -= Client_onDataSent; this.Clients.Remove(e.Client); foreach (ClientDisconnectedHandler cdh in PluginLoader.LoadPlugin(typeof(ClientDisconnectedHandler))) { try { cdh.OnDisconnected(sender, e); } catch { } } }
void client_onClientDisconnected(object sender, SocksClientEventArgs e) { e.Client.onClientDisconnected -= client_onClientDisconnected; this.Clients.Remove(e.Client); }
void OnClientDisconnected(object sender, SocksClientEventArgs e) { e.Client.OnClientDisconnected -= OnClientDisconnected; Clients.Remove(e.Client); }
/// <summary> /// Handle client disconnected callback. Useful for keeping track of connected clients. /// </summary> public abstract bool OnDisconnected(object sender, SocksClientEventArgs e);