Throw each CSocket as 1 thread ?
-
I use 1 my class derived from CSocket - MFC as usually. In server, I use an object of this class as a listening socket. Now, can you help me in solving this problem: -Once a client connect to server, whole transaction between server and that client is run in a separate thread. At this time, I can't solve it. I just use a CPtrList of many CMySocket, each in a connection. In my opinion, using thread is better, but I can't. Help me ! Hung Son A Vietnamese student i-g.hypermart.net dlhson2001@yahoo.com
-
I use 1 my class derived from CSocket - MFC as usually. In server, I use an object of this class as a listening socket. Now, can you help me in solving this problem: -Once a client connect to server, whole transaction between server and that client is run in a separate thread. At this time, I can't solve it. I just use a CPtrList of many CMySocket, each in a connection. In my opinion, using thread is better, but I can't. Help me ! Hung Son A Vietnamese student i-g.hypermart.net dlhson2001@yahoo.com
The moment a new socket connection is established, spawn a new thread. Though if there are too many connections in parallel, this is not a recommended method Nish
Regards, Nish Native CPian. Born and brought up on CP. With the CP blood in him.