[zeromq-dev] How to use ZeroMQ context with zauth?

Check Peck comptechgeeky at gmail.com
Mon Dec 15 22:20:32 CET 2014

I am using C++ bindings for ZeroMQ and I have declared context as -

    zmq::context_t&     context
    zauth_t             *m_auth;

Now I am trying to use Strawhouse security pattern in my application and
for which I need to czmq which is a C binding not C++ binding.

Now when I try to initialize zauth like below, it always fail during
compilation and I am not sure what's wrong?

    m_auth = zauth_new (*context);

Below is the compilation error -

In file included from
                 from /usr/local/include/boost/functional/hash/hash.hpp:529,
                 from /usr/local/include/boost/functional/hash.hpp:6,
                 from /usr/local/include/boost/regex/v4/basic_regex.hpp:23,
                 from /usr/local/include/boost/regex/v4/regex.hpp:67,
                 from /usr/local/include/boost/regex.hpp:31,
                 from /home/david/ZeroMQTester/test_queue.cpp:7:
/usr/include/c++/4.7/complex:379:5: note: template<class _Tp>
std::complex<_Tp> std::operator*(const std::complex<_Tp>&, const
/usr/include/c++/4.7/complex:379:5: note:   template argument
deduction/substitution failed:
/home/david/ZeroMQTester/test_queue.cpp:126:26: note:   âzmq::context_tâ is
not derived from âconst std::complex<_Tp>â
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20141215/2dc11d46/attachment.htm>

More information about the zeromq-dev mailing list