]> git.ipfire.org Git - thirdparty/vectorscan.git/commitdiff
smallwrite: remove unnecessary assertion
authorJustin Viiret <justin.viiret@intel.com>
Tue, 2 May 2017 00:20:59 +0000 (10:20 +1000)
committerMatthew Barr <matthew.barr@intel.com>
Tue, 30 May 2017 03:59:00 +0000 (13:59 +1000)
The alpha remap array is always big enough to remap characters. Silences
Coverity issue CID 167663.

src/smallwrite/smallwrite_build.cpp

index 4390020783e745d4fe7b3149ae111419b8ce9a1d..bb933cbe3b5570aab91de82184158e363ea2ba56 100644 (file)
@@ -698,7 +698,6 @@ unique_ptr<raw_dfa> buildDfa(LitTrie &trie, bool nocase) {
                 continue;
             }
             auto v_state = state_ids.at(v);
-            assert((u16)trie[v].c < alpha.size());
             u16 sym = alpha[trie[v].c];
             DEBUG_PRINTF("edge to %u on 0x%02x (sym %u)\n", v_state,
                          trie[v].c, sym);