Support addressing TIPC Port Identity

ZeroMQ currently supports location independent addressing using TIPC
Port Names with tipc://{type,instance}. This commits adds support for
connecting and binding using TIPC Port Identity addresses. To connect
using Port Identities the expected format is tipc://<Z.C.N:Ref>, e.g.
"tipc://<1.2.3:123123>". To bind using TIPC Port Identities the expected
format is "tipc://<*>".
This commit is contained in:
Pontus Sköldström
2018-02-19 17:34:40 +01:00
parent 4c7c9b87bf
commit 78aa9b1983
4 changed files with 93 additions and 10 deletions

View File

@@ -204,6 +204,11 @@ int zmq::tipc_connecter_t::open ()
{
zmq_assert (s == retired_fd);
// Cannot connect to random tipc addresses
if (addr->resolved.tipc_addr->is_random ()) {
errno = EINVAL;
return -1;
}
// Create the socket.
s = open_socket (AF_TIPC, SOCK_STREAM, 0);
if (s == -1)