sanchop22
sanchop22

Reputation: 2809

Killing TCP Client Threads of TCP Server in C#

i have a TCP server software. I open a thread for every TCP client. (This is not important why i open a thread for every TCP client.) I want to kick a TCP client any time and want to kill its thread. How can i find the thread of TCP client that i want to kick out of server?

Thank you.

Upvotes: 1

Views: 435

Answers (1)

usr
usr

Reputation: 171246

You need to keep track of all TcpClient's in existence. For example, use a list to store them. That way you have access to them.

Upvotes: 3

Related Questions