John Matthews wrote: > --- In [email protected], "John Matthews" <[EMAIL PROTECTED]> wrote: >> Thanks- I've added shutdown()s everywhere and that seems to have done >> the trick :-) > > Spoke too soon- I think all sockets are being shutdown (debug tells me > they are), but I still get an 'address already in use' from bind() > when I re-run the server. > > I'll try to post some code later, but if anyone has any ideas of what > I might be doing wrong... > > John
This is an OS-level issue. The OS will hang onto bound and (formerly) connected sockets for a while. You may be able to set a socket option to control this behavior (but may introduce other bugs). Best to just wait it out. -- Thomas Hruska CubicleSoft President Ph: 517-803-4197 *NEW* MyTaskFocus 1.1 Get on task. Stay on task. http://www.CubicleSoft.com/MyTaskFocus/
