Hi all,

I've added a feature to CZMQ that we could standardize across other
language bindings, and eventually get into libzmq.

If you bind to an interface and specify '*' as the port, it'll look
for an available port in the range 0xc000 - 0xffff, which is specified
by IANA for dynamic or private ports. The zsocket_bind() method then
returns the actual port number used, which can be communicated to
other 0MQ peers.

An example of use:

    int port = zsocket_bind (my_socket, "tcp://*:*");

-Pieter

[1] https://github.com/zeromq/czmq/blob/master/src/zsocket.c
_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to