[zeromq-dev] Problem with multiple sockets under Windows: Address already in use

Steven McCoy steven.mccoy at miru.hk
Mon Jun 20 16:58:45 CEST 2011

On 20 June 2011 10:12, Seref Arikan <serefarikan at kurumsalteknoloji.com>wrote:

> Thanks Martin,
> With the following modified code  below (assuming I'm doing the error
> handling right), I get no errors at all  I just get the "Assertion
> failed: Address already in use (..\..\..\src\mailbox.cpp:305)" output
> in the command prompt.
It would appear WinSock does not provide a return code for socket exhaustion
from *bind*/*connect*, this is a delayed error from *bind*.  On Windows XP
the default limit appears to be 3,975 sockets between 1,025 and 5,000:


> *The *MaxUserPort* registry value sets the value to use for the maximum
> value of the dynamic client port range. You must restart the computer for
> this setting to take effect.

Ideally along with out-of-memory errors ZeroMQ should be handling socket and
file handle exhaustion.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20110620/ace9e3a7/attachment.htm>

More information about the zeromq-dev mailing list