[zeromq-dev] zmq2 : bug in devpoll_t
Jon Dyte
jon at totient.co.uk
Wed Nov 18 22:10:44 CET 2009
Hi
There is a bug in the constructor of zmq::devpoll_t,
the stopping data member is not initialised and in cases
where the the random memory value is true, it leads to the
devpoll_t::loop() exiting immediately; because by this time the socket has
actually been created clients can actually connect but nothing happens as
there is no IO thread.
I submit this patch under the MIT license.
Thanks,
Jon
diff --git a/src/devpoll.cpp b/src/devpoll.cpp
index f28d55e..7a9ab90 100644
--- a/src/devpoll.cpp
+++ b/src/devpoll.cpp
@@ -38,6 +38,7 @@
#include "i_poll_events.hpp"
zmq::devpoll_t::devpoll_t ()
+ : stopping(false)
{
// Get limit on open files
struct rlimit rl;
More information about the zeromq-dev
mailing list