summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Sustrik <sustrik@250bpm.com>2011-02-23 11:48:49 +0100
committerMartin Sustrik <sustrik@250bpm.com>2011-02-23 11:48:49 +0100
commit29e0e7dbadfcd0bab70feee119bd7c5e623b38d4 (patch)
treef4e78b983f5bdfcf5f1df392d2757473e5888f98
parent820fec7f28b54dc5fc16a38eceb405e9af41260c (diff)
Incorrect PGM sender/receiver creation fixed
Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
-rw-r--r--src/connect_session.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/connect_session.cpp b/src/connect_session.cpp
index fda39d6..0b6c16c 100644
--- a/src/connect_session.cpp
+++ b/src/connect_session.cpp
@@ -72,7 +72,7 @@ void zmq::connect_session_t::start_connecting (bool wait_)
// At this point we'll create message pipes to the session straight
// away. There's no point in delaying it as no concept of 'connect'
// exists with PGM anyway.
- if (options.requires_out) {
+ if (options.type == ZMQ_PUB || options.type == ZMQ_XPUB) {
// PGM sender.
pgm_sender_t *pgm_sender = new (std::nothrow) pgm_sender_t (
@@ -84,7 +84,7 @@ void zmq::connect_session_t::start_connecting (bool wait_)
send_attach (this, pgm_sender, blob_t ());
}
- else if (options.requires_in) {
+ else if (options.type == ZMQ_SUB || options.type == ZMQ_XSUB) {
// PGM receiver.
pgm_receiver_t *pgm_receiver = new (std::nothrow) pgm_receiver_t (