From 7ec58b279a806bb2c43214a1eae5df13ace4d8eb Mon Sep 17 00:00:00 2001 From: Simon Giesecke Date: Mon, 23 Oct 2017 11:12:15 +0200 Subject: [PATCH] Problem: one missed optimization opportunity for blob_t map lookup Solution: create referencing blob_t --- src/router.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/router.cpp b/src/router.cpp index 39582d69..3e7106bd 100644 --- a/src/router.cpp +++ b/src/router.cpp @@ -208,7 +208,8 @@ int zmq::router_t::xsend (msg_t *msg_) // Find the pipe associated with the routing id stored in the prefix. // If there's no such pipe just silently ignore the message, unless // router_mandatory is set. - blob_t routing_id ((unsigned char*) msg_->data (), msg_->size ()); + blob_t routing_id ((unsigned char*) msg_->data (), msg_->size (), + zmq::reference_tag_t()); outpipes_t::iterator it = outpipes.find (routing_id); if (it != outpipes.end ()) {