On Sat, Dec 18, 2010 at 12:30 AM, Martin Sustrik <sust...@250bpm.com> wrote:
> Dhammika,
>
>>>> 1) Using one zmq context, I bind four separate zmq sockets (in java) to
>>>> the same ipc port; e.g. "ipc://tmp/test"
>>>
>>> Hm, you should be able to bind at most one socket to a particular
>>> endpoint. Are you sure all the four binds succeed?
>>>
>> All four binds will succeed, as we unlink() before we call bind().
>> This is a bug and comments here are misleading.
>
> True.
>
> What about not unlinking the file at bind? Would the duplicit bind()s
> produce errors?

Yes, duplicate binds will return EADDRINUSE.


And would the OS recognise when an applicaion fails and
> unlock the file so that different application can bind to the endpoint?
>

No, OS doesn't delete it on app exit.
app has to remove it, ie. call zmq socket close().


Dhammika
_______________________________________________
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to