[zeromq-dev] Issue 85 & 92
Pieter Hintjens
ph at imatix.com
Sat Oct 2 03:21:30 CEST 2010
On Fri, Oct 1, 2010 at 7:42 PM, Martin Sustrik <sustrik at 250bpm.com> wrote:
> That's OK, the question is what to do with the socket that is still open.
Why are you asking this? Surely if the context is terminated, any
further operation on any socket will fail, just as any blocking call
on a socket fails if you terminate the context.
If there are some consequences of doing the obvious thing, which I'm
unaware of, maybe you could explain those.
zmq_term should not block forever when there is no work to do, whether
or not I closed any sockets beforehand. If the API detects an error
it should report it. It should not cause my application to hang.
The question is, what BSD socket semantics are you emulating here?
There is no requirement in POSIX that sockets be closed before exiting
an application, it happens automatically at exit.
-Pieter
More information about the zeromq-dev
mailing list