Board index » cppbuilder » TCP and KeepAlive
XXXX@XXXXX.COM
![]() CBuilder Developer |
XXXX@XXXXX.COM
![]() CBuilder Developer |
TCP and KeepAlive2007-11-29 01:43:11 AM cppbuilder41 Hi guys, sorry for my english. I need allow / disallow the TCP KeepAlive protocol in TCPServer application using Indy components, I investigated the use of SetSocketOpt method, but I don't make the correct funtionality. Example on my socket connection on connect handler: MyClientThread::ClientConnected... { bool bFlag = 1; Connection->Socket->Binding->SetSockOpt( SOL_SOCKET, Id_SO_KEEPALIVE, (char *) &bFlag, sizeof(bFlag)); } Thanks in advance ! |