mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-27 19:10:22 +01:00
Added assert on duplicate id in ROUTER and STREAM sockets. Updated man to reflect this change. Modified test case to match.
This commit is contained in:
@@ -268,10 +268,10 @@ void zmq::stream_t::identify_peer (pipe_t *pipe_)
|
||||
connect_rid.clear ();
|
||||
outpipes_t::iterator it = outpipes.find (identity);
|
||||
if (it != outpipes.end ())
|
||||
goto d;
|
||||
zmq_assert(false);
|
||||
}
|
||||
else {
|
||||
d: put_uint32 (buffer + 1, next_rid++);
|
||||
put_uint32 (buffer + 1, next_rid++);
|
||||
identity = blob_t (buffer, sizeof buffer);
|
||||
memcpy (options.identity, identity.data (), identity.size ());
|
||||
options.identity_size = identity.size ();
|
||||
|
||||
Reference in New Issue
Block a user