[zeromq-dev] Monitor event data & memory access

Johnny Gozde johnny at jgoz.net
Tue Oct 23 19:15:34 CEST 2012

I'm in the process of updating the C# bindings to support the new
zmq_socket_monitor API, and I'm seeing inconsistent results from received
monitor events. Specifically, when reading `addr` on CONNECTED and CLOSED
events, the string it used to point to is no longer available, so it just
reads garbage data.

Is this the intended behaviour? Passing the address of the string instead
of the string itself keeps the overhead low and requiring the monitor
receiver to run in the same process should make this somewhat safe, but
this behaviour should be noted in the documentation at the very least.

Note that I'm testing this on Windows; the observed behaviour can be
replicated by running the example code from the man page.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20121023/6d3a688c/attachment.htm>

More information about the zeromq-dev mailing list