Forum Discussion
Altera_Forum
Honored Contributor
13 years ago --- Quote Start --- Hi everyone, In TCP client programming, we use connect() to establish a new TCP connection. connect() returns zero on success or -1 on error. If server is up , connect() returns zero and client connects to server. what if server is down? I placed connect() in while loop with a condition to exit from while loop when it returns ZERO(connects successfully). It doesn't work......... suggest me a solution in client program to connect a server which can come UP and go DOWN at any time. --- Quote End --- Hi,rahul Can you still remember how to solve the problem, which is metioned previously.I can send words or command via Telnet or Ping, when I use a router(100M). But, when I I directly connect the board and PC with a cross-over cable or a router(1000M), I failed. I hope you could give me some advice.