File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -86,6 +86,12 @@ typedef struct {
86
86
} zmq_event_t ;
87
87
#endif
88
88
89
+ // Avoid using deprecated message receive function when possible
90
+ #if ZMQ_VERSION < ZMQ_MAKE_VERSION(3, 2, 0)
91
+ # define zmq_msg_recv zmq_recvmsg
92
+ #endif
93
+
94
+
89
95
// In order to prevent unused variable warnings when building in non-debug
90
96
// mode use this macro to make assertions.
91
97
#ifndef NDEBUG
@@ -657,7 +663,7 @@ namespace zmq
657
663
while (true ) {
658
664
zmq_msg_t eventMsg;
659
665
zmq_msg_init (&eventMsg);
660
- rc = zmq_recvmsg (s, &eventMsg, 0 );
666
+ rc = zmq_msg_recv (s, &eventMsg, 0 );
661
667
if (rc == -1 && zmq_errno () == ETERM)
662
668
break ;
663
669
assert (rc != -1 );
@@ -674,7 +680,7 @@ namespace zmq
674
680
#ifdef ZMQ_NEW_MONITOR_EVENT_LAYOUT
675
681
zmq_msg_t addrMsg;
676
682
zmq_msg_init (&addrMsg);
677
- rc = zmq_recvmsg (s, &addrMsg, 0 );
683
+ rc = zmq_msg_recv (s, &addrMsg, 0 );
678
684
if (rc == -1 && zmq_errno () == ETERM)
679
685
break ;
680
686
assert (rc != -1 );
You can’t perform that action at this time.
0 commit comments