Hello,
On Wed, 24 Apr 2002 lidsa@xxxxxxxxxxxxx wrote:
> The example can work if I delete the code "setsockopt(listenfd,
> SOL_SOCKET, SO_REUSEADDR, &flag,sizeof(flag))".I initialized the variable
> flag follow your message
> and recomplied again.But it can not work still.
> I debug fowarder with gdb ,I found that error came out when
> "accept",The errorno is 3.
>
I forgot initializing the other variable cliaddrlen in this simple
example, sorry.
Please apply the attached diff to forwarder.c,
cd <directory>/tcpsp/example
patch -p0 < <your-directory>/example.diff
compile it again, then it should work.
Thanks,
Wensong
example.diff
Description: Text document
|