]> granicus.if.org Git - xz/commitdiff
Fix test_filter_flags to match the new restriction of lc+lp.
authorLasse Collin <lasse.collin@tukaani.org>
Fri, 20 Jun 2008 14:16:32 +0000 (17:16 +0300)
committerLasse Collin <lasse.collin@tukaani.org>
Fri, 20 Jun 2008 14:16:32 +0000 (17:16 +0300)
tests/test_filter_flags.c

index 8df6da6cb9976ef6d9b2c6be95a120594d51f374..dde01381eb71a20d3796179930f81253ec5b95cb 100644 (file)
@@ -258,6 +258,9 @@ test_lzma(void)
                                lp <= LZMA_LITERAL_POS_BITS_MAX; ++lp) {
                        for (uint32_t pb = LZMA_POS_BITS_MIN;
                                        pb <= LZMA_POS_BITS_MAX; ++pb) {
+                               if (lc + lp > LZMA_LITERAL_BITS_MAX)
+                                       continue;
+
                                options.literal_context_bits = lc;
                                options.literal_pos_bits = lp;
                                options.pos_bits = pb;