Compilation issue on Debian Stretch due to explicit keyword in CPPZMQ
Opened this issue · 0 comments
Deleted user commented
Due to an explicit cast "issue" in some CPPZMQ versions (zeromq/cppzmq@bd288a5) (i.e. it happend on Debian Stretch for me), nzmqt cannot compile using newer compilers.
Fix:
Fix affects file: /include/nzmqt/impl.hpp
Function: NZMQT_INLINE void PollingZMQContext::registerSocket(ZMQSocket* socket_)
Change: Force cast to void* when creating new pollitem:
from: pollitem_t pollItem = { socket_, 0, ZMQSocket::EVT_POLLIN, 0 };
to: pollitem_t pollItem = { static_cast<void>(*socket_), 0, ZMQSocket::EVT_POLLIN, 0 };