I am writing a program that listens on a socket. Today I introduced quite a few changes and a problem popped up which it was not there yesterday.
If after closing the program I start it immediately I get error 48 (address already in use) on bind. I am at a loss as to what changes could bring this disaster upon me but in the meantime noticed something in the documentation:
bind(2)
I do not do that. Can that be the ultimate cause of the problem? I am asking this because to be honest I do not fancy deleting files which I didn't create. After all the nuisance lasts only about a minute.
-
If after closing the program I start it immediately I get error 48 (address already in use) on bind. I am at a loss as to what changes could bring this disaster upon me but in the meantime noticed something in the documentation:
bind(2)
Binding an address in the UNIX domain creates a socket in the file system that must be deleted by the caller when it is no longer needed (using unlink(2)).
I do not do that. Can that be the ultimate cause of the problem? I am asking this because to be honest I do not fancy deleting files which I didn't create. After all the nuisance lasts only about a minute.
-