From 6fd3f0de2c083ddb8d96e09f62dc2285c3858378 Mon Sep 17 00:00:00 2001 From: Pat Marion Date: Thu, 13 Nov 2025 15:49:24 -0500 Subject: [PATCH] Build regex from channel and not sub->channel. The sub->channel is a shortened string clipped at ZCM_CHANNEL_MAXLEN=32 while channel is the full string. --- zcm/blocking.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zcm/blocking.cpp b/zcm/blocking.cpp index eaddd0f4..83b2a4f1 100644 --- a/zcm/blocking.cpp +++ b/zcm/blocking.cpp @@ -489,7 +489,7 @@ zcm_sub_t* zcm_blocking_t::subscribe(const string& channel, sub->usr = usr; sub->regex = isRegexChannel(channel); if (sub->regex) { - sub->regexobj = (void*) new std::regex(sub->channel); + sub->regexobj = (void*) new std::regex(channel); ZCM_ASSERT(sub->regexobj); subsRegex[channel].push_back(sub); } else {