In zmq.cpp function zmq_send(), it doesn't _close but has a comment that this is dependent on knowledge of the implementation, which may change.
Should bindings be assuming this implementation detail? On Apr 27, 2013 12:18 AM, "Pieter Hintjens" <[email protected]> wrote: > For what it's worth, there were two cases in CZMQ that did _close > after _send; I've removed these and re-run the tests under Valgrind > and it does not leak memory, as expected. > > -Pieter > > On Fri, Apr 26, 2013 at 6:15 PM, Pieter Hintjens <[email protected]> wrote: > > On Fri, Apr 26, 2013 at 3:54 PM, Alexey Melnichuk <[email protected]> > wrote: > > > >> I write Lua binding to ZeroMQ3. > >> And i have 2 question: > >> 1. Do i need close message after send/move. > > > > No, you don't. It's not well documented though but _send takes > > ownership, and _close isn't needed. > > > >> Manual says: > >> `The zmq_msg_t structure passed to zmq_msg_send() is nullified during > the call`. > >> But do that mean I have to call zmq_msg_close? > >> 2. zmq_ctx_destroy in libzmq (3.3.0) marked as `Old (legacy) API` > >> Manual has nothing about zmq_ctx_term. > > > > We had used zmq_ctx_destroy for a while, then switched to zmq_ctx_term > > because people felt the context wasn't destroyed, just terminated. > > However the man pages still speak of "destroying the context", so we > > need to fix that. > > > > My fault about the man pages not mentioning zmq_ctx_term; I had > > uploaded them from an old version. Fixing that right now. > > > > -Pieter > _______________________________________________ > zeromq-dev mailing list > [email protected] > http://lists.zeromq.org/mailman/listinfo/zeromq-dev >
_______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
