Hi Dhammika, dhamm...@gmail.com said: > > > > +int zmq::zmq_connecter_t::get_reconnect_period () > > +{ > > +#if defined ZMQ_HAVE_WINDOWS > > + return (reconnect_period + (((int)GetCurrentProcessId () * 13) > > + % reconnect_period)); > > +#else > > + return (reconnect_period + (((int)getpid () * 13) % reconnect_period)); > > +#endif > > +} > > + > > > This could throw a SIGFPE (floating point exception). > Do we check for reconnect_period > 0?
No, but if you set reconnect_period to 0 then any number of things will break. I'd not worry about that too much; changing stuff in config.hpp is something 90% or more people will never touch. Incidentally if you can think of a better distribution function than the getpid() based one I wrote, go for it. That was just a quick hack to get 300 nodes all reconnecting at the same time to not hammer the server. -mato _______________________________________________ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev