This is an automated email from the ASF dual-hosted git repository.
xyz pushed a commit to branch branch-2.9
in repository https://gitbox.apache.org/repos/asf/pulsar.git
The following commit(s) were added to refs/heads/branch-2.9 by this push:
new 309d0f3f04e Fix broken C++ unit tests
309d0f3f04e is described below
commit 309d0f3f04e7d46f1fec734cdfaf42eb49e4e009
Author: Yunze Xu <[email protected]>
AuthorDate: Tue Nov 15 10:22:43 2022 +0800
Fix broken C++ unit tests
https://github.com/apache/pulsar/pull/15726 changed the API of
BlockingQueue::add and it should be cherry-picked. Ignore the returned
value to make compilation succeed.
---
pulsar-client-cpp/lib/MultiTopicsConsumerImpl.cc | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/pulsar-client-cpp/lib/MultiTopicsConsumerImpl.cc
b/pulsar-client-cpp/lib/MultiTopicsConsumerImpl.cc
index 7dc8dd3a551..4e150610b92 100644
--- a/pulsar-client-cpp/lib/MultiTopicsConsumerImpl.cc
+++ b/pulsar-client-cpp/lib/MultiTopicsConsumerImpl.cc
@@ -458,7 +458,8 @@ void MultiTopicsConsumerImpl::messageReceived(Consumer
consumer, const Message&
lock.unlock();
}
- if (messages_.push(msg) && messageListener_) {
+ messages_.push(msg);
+ if (messageListener_) {
listenerExecutor_->postWork(
std::bind(&MultiTopicsConsumerImpl::internalListener,
shared_from_this(), consumer));
}