the address syntax may be different for zmq_bind() and zmq_connect() especially for the tcp, pgm and epgm transports.

following a zmq_bind(), the socket enters a mute state unless or until at least one incoming or outgoing connection is made, at which point the socket enters a ready state. In the mute state, the socket blocks or drops messages according to the socket type, as defined in zmq_socket(3). By contrast, following a libzmq:zmq_connect[3], the socket enters the ready state.

Return value

The zmq_bind() function returns zero if successful. Otherwise it returns -1 and sets errno to one of the values defined below.

Errors

EINVAL

The endpoint supplied is invalid.

EPROTONOSUPPORT

The requested transport protocol is not supported.

ENOCOMPATPROTO

The requested transport protocol is not compatible with the socket type.