From 6704c8e070ead2ab459b05c2c3b214eafc34b3a8 Mon Sep 17 00:00:00 2001 From: vng Date: Mon, 27 Apr 2015 17:51:39 +0300 Subject: [PATCH] [search] Fixed bug from previous commit here. --- search/feature_offset_match.hpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/search/feature_offset_match.hpp b/search/feature_offset_match.hpp index 4b8c128a74..69748356b1 100644 --- a/search/feature_offset_match.hpp +++ b/search/feature_offset_match.hpp @@ -162,13 +162,10 @@ void PrefixMatchInTrie(TrieIterator const & trieRoot, unique_ptr const pIter(trieQueue.back()); trieQueue.pop_back(); - ASSERT_LESS(pIter->m_edge.size(), std::numeric_limits::max(), ()); - uint32_t const edgeCount = static_cast(pIter->m_edge.size()); - - for (uint32_t i = 0; i < edgeCount; ++i) + for (size_t i = 0; i < pIter->m_value.size(); ++i) f(pIter->m_value[i]); - for (uint32_t i = 0; i < edgeCount; ++i) + for (size_t i = 0; i < pIter->m_edge.size(); ++i) trieQueue.push_back(pIter->GoToEdge(i)); } }