Commit 5205415b authored by Lourens Naudé's avatar Lourens Naudé

Fix addresses on triggered events

parent 37f8ce69
......@@ -1063,7 +1063,7 @@ void zmq::socket_base_t::event_connect_delayed (const char *addr_, int err_)
if (monitor_events & ZMQ_EVENT_CONNECT_DELAYED) {
zmq_event_t event;
event.event = ZMQ_EVENT_CONNECT_DELAYED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.connect_delayed.addr = const_cast <char *> (addr_);
event.data.connect_delayed.err = err_;
monitor_event (event);
}
......@@ -1074,7 +1074,7 @@ void zmq::socket_base_t::event_connect_retried (const char *addr_, int interval_
if (monitor_events & ZMQ_EVENT_CONNECT_RETRIED) {
zmq_event_t event;
event.event = ZMQ_EVENT_CONNECT_RETRIED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.connect_retried.addr = const_cast <char *> (addr_);
event.data.connect_retried.interval = interval_;
monitor_event (event);
}
......@@ -1085,7 +1085,7 @@ void zmq::socket_base_t::event_listening (const char *addr_, int fd_)
if (monitor_events & ZMQ_EVENT_LISTENING) {
zmq_event_t event;
event.event = ZMQ_EVENT_LISTENING;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.listening.addr = const_cast <char *> (addr_);
event.data.listening.fd = fd_;
monitor_event (event);
}
......@@ -1096,7 +1096,7 @@ void zmq::socket_base_t::event_bind_failed (const char *addr_, int err_)
if (monitor_events & ZMQ_EVENT_BIND_FAILED) {
zmq_event_t event;
event.event = ZMQ_EVENT_BIND_FAILED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.bind_failed.addr = const_cast <char *> (addr_);
event.data.bind_failed.err = err_;
monitor_event (event);
}
......@@ -1107,7 +1107,7 @@ void zmq::socket_base_t::event_accepted (const char *addr_, int fd_)
if (monitor_events & ZMQ_EVENT_ACCEPTED) {
zmq_event_t event;
event.event = ZMQ_EVENT_ACCEPTED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.accepted.addr = const_cast <char *> (addr_);
event.data.accepted.fd = fd_;
monitor_event (event);
}
......@@ -1118,7 +1118,7 @@ void zmq::socket_base_t::event_accept_failed (const char *addr_, int err_)
if (monitor_events & ZMQ_EVENT_ACCEPT_FAILED) {
zmq_event_t event;
event.event = ZMQ_EVENT_ACCEPT_FAILED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.accept_failed.addr = const_cast <char *> (addr_);
event.data.accept_failed.err= err_;
monitor_event (event);
}
......@@ -1129,7 +1129,7 @@ void zmq::socket_base_t::event_closed (const char *addr_, int fd_)
if (monitor_events & ZMQ_EVENT_CLOSED) {
zmq_event_t event;
event.event = ZMQ_EVENT_CLOSED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.closed.addr = const_cast <char *> (addr_);
event.data.closed.fd = fd_;
monitor_event (event);
}
......@@ -1140,7 +1140,7 @@ void zmq::socket_base_t::event_close_failed (const char *addr_, int err_)
if (monitor_events & ZMQ_EVENT_CLOSE_FAILED) {
zmq_event_t event;
event.event = ZMQ_EVENT_CLOSE_FAILED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.close_failed.addr = const_cast <char *> (addr_);
event.data.close_failed.err = err_;
monitor_event (event);
}
......@@ -1151,7 +1151,7 @@ void zmq::socket_base_t::event_disconnected (const char *addr_, int fd_)
if (monitor_events & ZMQ_EVENT_DISCONNECTED) {
zmq_event_t event;
event.event = ZMQ_EVENT_DISCONNECTED;
event.data.connected.addr = const_cast <char *> (addr_);
event.data.disconnected.addr = const_cast <char *> (addr_);
event.data.disconnected.fd = fd_;
monitor_event (event);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment