I am writing client program, using sockets. The client also has to accept responses.
I connect to the server ok, can send requests ok. The problem is when I try to recv().
The main program deals with the send()ing stuff, I have fork()ed a new process to sit and recv() responses from the server.
The program breaks after it has recieved one responce. I am using the same file descriptor for both send() and recv(), could this be the problem?
The error message is:
recv: Connection reset by peer
Any help would be appreciated,
Cheers