mirror of
https://github.com/zeromq/cppzmq.git
synced 2025-01-06 00:31:14 +01:00
Merge pull request #509 from hirokiht/fix_monitor_draft_libzmq-4-3
Fix handshake event don't need DRAFT API in libzmq v4.3.0 and above
This commit is contained in:
commit
b4c5c6ac77
6
zmq.hpp
6
zmq.hpp
@ -2397,8 +2397,7 @@ class monitor_t
|
|||||||
case ZMQ_EVENT_DISCONNECTED:
|
case ZMQ_EVENT_DISCONNECTED:
|
||||||
on_event_disconnected(*event, address.c_str());
|
on_event_disconnected(*event, address.c_str());
|
||||||
break;
|
break;
|
||||||
#ifdef ZMQ_BUILD_DRAFT_API
|
#if ZMQ_VERSION >= ZMQ_MAKE_VERSION(4, 3, 0) || (defined(ZMQ_BUILD_DRAFT_API) && ZMQ_VERSION >= ZMQ_MAKE_VERSION(4, 2, 3))
|
||||||
#if ZMQ_VERSION >= ZMQ_MAKE_VERSION(4, 2, 3)
|
|
||||||
case ZMQ_EVENT_HANDSHAKE_FAILED_NO_DETAIL:
|
case ZMQ_EVENT_HANDSHAKE_FAILED_NO_DETAIL:
|
||||||
on_event_handshake_failed_no_detail(*event, address.c_str());
|
on_event_handshake_failed_no_detail(*event, address.c_str());
|
||||||
break;
|
break;
|
||||||
@ -2411,14 +2410,13 @@ class monitor_t
|
|||||||
case ZMQ_EVENT_HANDSHAKE_SUCCEEDED:
|
case ZMQ_EVENT_HANDSHAKE_SUCCEEDED:
|
||||||
on_event_handshake_succeeded(*event, address.c_str());
|
on_event_handshake_succeeded(*event, address.c_str());
|
||||||
break;
|
break;
|
||||||
#elif ZMQ_VERSION >= ZMQ_MAKE_VERSION(4, 2, 1)
|
#elif defined(ZMQ_BUILD_DRAFT_API) && ZMQ_VERSION >= ZMQ_MAKE_VERSION(4, 2, 1)
|
||||||
case ZMQ_EVENT_HANDSHAKE_FAILED:
|
case ZMQ_EVENT_HANDSHAKE_FAILED:
|
||||||
on_event_handshake_failed(*event, address.c_str());
|
on_event_handshake_failed(*event, address.c_str());
|
||||||
break;
|
break;
|
||||||
case ZMQ_EVENT_HANDSHAKE_SUCCEED:
|
case ZMQ_EVENT_HANDSHAKE_SUCCEED:
|
||||||
on_event_handshake_succeed(*event, address.c_str());
|
on_event_handshake_succeed(*event, address.c_str());
|
||||||
break;
|
break;
|
||||||
#endif
|
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
on_event_unknown(*event, address.c_str());
|
on_event_unknown(*event, address.c_str());
|
||||||
|
Loading…
Reference in New Issue
Block a user