[zeromq-dev] question about czmq zctx_destroy
Michel Pelletier
pelletier.michel at gmail.com
Thu Apr 18 07:17:57 CEST 2013
This is nagging me in a minor way:
CZMQ_EXPORT zctx_t *
zctx_new (void);
// Destroy context and all sockets in it, replaces zmq_term
CZMQ_EXPORT void
zctx_destroy (zctx_t **self_p);
Why does new return a pointer to a context, but destroy wants a pointer to
that pointer? I'm trying to call this functions via an FFI interface, but
I can't pass the result of new to destroy and I don't have the equivalent
of the & operator in the FFI environment.
I've got a workaround, but is there a particular reason for this?
-Michel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20130417/c782842b/attachment.htm>
More information about the zeromq-dev
mailing list