Skip to content

Commit

Permalink
Merge pull request zeromq#3996 from tarmo/xpub-unmatch
Browse files Browse the repository at this point in the history
Problem: XPUB keeps matched pipes between failed non-blocking sends
  • Loading branch information
bluca authored Jul 29, 2020
2 parents 49f4c18 + 27bf9bf commit 7deb8de
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
15 changes: 15 additions & 0 deletions RELICENSE/tarmo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Permission to Relicense under MPLv2 or any other OSI approved license chosen by the current ZeroMQ BDFL

This is a statement by Tarmo Tänav that grants permission to
relicense its copyrights in the libzmq C++ library (ZeroMQ) under the
Mozilla Public License v2 (MPLv2) or any other Open Source Initiative
approved license chosen by the current ZeroMQ BDFL (Benevolent
Dictator for Life).

A portion of the commits made by the Github handle "tarmo", with
commit author "Tarmo Tänav <[email protected]>", are copyright of Tarmo Tänav.
This document hereby grants the libzmq project team to relicense libzmq,
including all past, present and future contributions of the author listed above.

Tarmo Tänav
2020/08/29
3 changes: 3 additions & 0 deletions src/xpub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,9 @@ int zmq::xpub_t::xsend (msg_t *msg_)

// For the first part of multi-part message, find the matching pipes.
if (!_more_send) {
// Ensure nothing from previous failed attempt to send is left matched
_dist.unmatch ();

if (unlikely (_manual && _last_pipe && _send_last_pipe)) {
_subscriptions.match (static_cast<unsigned char *> (msg_->data ()),
msg_->size (), mark_last_pipe_as_matching,
Expand Down

0 comments on commit 7deb8de

Please sign in to comment.