Client server problem
-
hi ppl, I am creating a Client server application using Asyncsockets using MFC. my application is running well on the local server. but the problem starts when it's client side is used on other computers on lan Like for the first time the client connects to the server every thing goes on smoothly but when the connection closes from the client side the server closes all the connection but on the client side the connection goes to the FIN_WAIT2 and reamins there and no message can be sent from there on so the application halts. I donn know what to do help me?
-
hi ppl, I am creating a Client server application using Asyncsockets using MFC. my application is running well on the local server. but the problem starts when it's client side is used on other computers on lan Like for the first time the client connects to the server every thing goes on smoothly but when the connection closes from the client side the server closes all the connection but on the client side the connection goes to the FIN_WAIT2 and reamins there and no message can be sent from there on so the application halts. I donn know what to do help me?
ok i think i also faced similar situation when i encounter this problem. the solution is that you override the function OnClose() of AsyncSocket of MFC and In OnClose() close the socket connectiong socket ok i think it work:rose: Alok Gupta visit me at http://alok.stormpages.com
-
ok i think i also faced similar situation when i encounter this problem. the solution is that you override the function OnClose() of AsyncSocket of MFC and In OnClose() close the socket connectiong socket ok i think it work:rose: Alok Gupta visit me at http://alok.stormpages.com
hi alok, thanks a lot for ur reply, but eventually i figured out my problem was not related with opening or closing but what i am using is ASyncSockets which are by default NON blocking sockets as a results the connection closes automatically if there is no buffer recieved so i used CSocket class ie a Blocking Socket class as a result untill unless the Buffer is recieved the connection is alive. thanks a lot again