diff options
author | Yury Melnichek <melnichek@gmail.com> | 2012-06-27 02:03:37 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:40:16 +0300 |
commit | 7c39c46830edc1956671d4cc9191143197e26c41 (patch) | |
tree | 4bf6ecb19fc961251c1c0bfb1981ee33a2aea89f /coding | |
parent | 72d04eba89493bbd0d80673b38ae4c7e707b169c (diff) |
Fix minor bug in trie_builder.hpp
Diffstat (limited to 'coding')
-rw-r--r-- | coding/trie_builder.hpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/coding/trie_builder.hpp b/coding/trie_builder.hpp index e057d1df7d..f14461284c 100644 --- a/coding/trie_builder.hpp +++ b/coding/trie_builder.hpp @@ -250,7 +250,8 @@ void Build(SinkT & sink, IterT const beg, IterT const end, EdgeBuilderT const & for (IterT it = beg; it != end; ++it) { ElementT e = *it; - if (e == prevE) continue; + if (e == prevE && it != beg) + continue; TrieChar const * const pKeyData = e.GetKeyData(); TrieString key(pKeyData, pKeyData + e.GetKeySize()); |