[zeromq-dev] Newbie Bait Request: Debug "Warning" mechanism.
ph at imatix.com
Tue Aug 17 12:24:06 CEST 2010
On Tue, Aug 17, 2010 at 6:45 AM, Oliver Smith <oliver at kfs.org> wrote:
> Might it be a good idea to introduce a warnings system into the ZeroMQ debug-build flavor.
> debugWarn(ZMQ_WARNING_33) ; // ZeroMQ Caution #33: Application called recv() on a ZMQ_SUB socket without subscribing to any topics. (See zmq_setsockopt).
This is certainly an error everyone hits and it's so flagrant that it
feels like a design issue. There is no validity in doing a blocking
recv on a SUB socket that has no subscriptions.
I'd like to see 0MQ assert if an app tries to do this. Does anyone
find this unreasonable?
If the requirement is to wait for term() there are surely more
explicit ways than abusing SUB sockets.
iMatix - www.imatix.com
More information about the zeromq-dev