summaryrefslogtreecommitdiff
path: root/src/dist.cpp
diff options
context:
space:
mode:
authorMartin Sustrik <sustrik@250bpm.com>2011-06-12 10:19:21 +0200
committerMartin Sustrik <sustrik@250bpm.com>2011-06-12 10:19:21 +0200
commite080e3e8b620b0e7ed02c28712a0c92b08de3451 (patch)
tree7e7aedfca8dd91e84d0825d251d122d3fe4ce7b3 /src/dist.cpp
parentbd86def1c799a35d5cef0c0a9a1347a18fea227e (diff)
Publisher-side filtering for multi-part messages fixed
Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
Diffstat (limited to 'src/dist.cpp')
-rw-r--r--src/dist.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/dist.cpp b/src/dist.cpp
index 707b9c1..15bd168 100644
--- a/src/dist.cpp
+++ b/src/dist.cpp
@@ -70,6 +70,11 @@ void zmq::dist_t::match (pipe_t *pipe_)
matching++;
}
+void zmq::dist_t::unmatch ()
+{
+ matching = 0;
+}
+
void zmq::dist_t::terminated (pipe_t *pipe_)
{
// Remove the pipe from the list; adjust number of matching, active and/or
@@ -115,9 +120,6 @@ int zmq::dist_t::send_to_matching (msg_t *msg_, int flags_)
if (!msg_more)
active = eligible;
- // Mark all the pipes as non-matching.
- matching = 0;
-
more = msg_more;
return 0;