[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[MIT-Scheme-devel] server socket closing problem
From: |
Chris Hanson |
Subject: |
[MIT-Scheme-devel] server socket closing problem |
Date: |
Sun, 17 Aug 2003 08:42:27 -0400 |
User-agent: |
IMAIL/1.20; Edwin/3.114; MIT-Scheme/7.8.0 |
Date: Sat, 16 Aug 2003 23:03:09 -0700
From: "Arthur A. Gleckler" <address@hidden>
Can someone explain the behavior in the transcript below? I've
been working through the MIT Scheme source code and setting
breakpoints, but I can't explain it. The summary is that opening
and closing a server socket correctly closes the socket so that it
can be opened again on the same network port, but only if no
connection was accepted on that server socket while it was open.
This is correct operation, given that MIT Scheme doesn't set
SO_REUSEADDR on the socket. If you look at the output of netstat,
you'll see that the connection is in one of the wait states, which
prevents the port from being reopened. It will close after about 70
seconds, at which point you can reopen the server socket.
Last month I changed the code to set SO_REUSEADDR, so the next release
won't have this problem.