When listening on a socket, if the local port is already in use it should fail, however the vm currently assumes that the listen() call is successful. This patch implements a similar check as the connect call. Note that the Windows implementation does not have this issue.
When listening on a socket, if the local port is already in use it should fail, however the vm currently assumes that the listen() call is successful. This patch implements a similar check as the connect call. Note that the Windows implementation does not have this issue.