=========================================================================== * Check that the match at match_start is indeed a match. */
(s, start, match, length)
| 1230 | * Check that the match at match_start is indeed a match. |
| 1231 | */ |
| 1232 | local void check_match(s, start, match, length) |
| 1233 | deflate_state *s; |
| 1234 | IPos start, match; |
| 1235 | int length; |
| 1236 | { |
| 1237 | /* check that the match is indeed a match */ |
| 1238 | if (zmemcmp(s->window + match, |
| 1239 | s->window + start, length) != EQUAL) { |
| 1240 | fprintf(stderr, " start %u, match %u, length %d\n", |
| 1241 | start, match, length); |
| 1242 | do { |
| 1243 | fprintf(stderr, "%c%c", s->window[match++], s->window[start++]); |
| 1244 | } while (--length != 0); |
| 1245 | z_error("invalid match"); |
| 1246 | } |
| 1247 | if (z_verbose > 1) { |
| 1248 | fprintf(stderr,"\\[%d,%d]", start-match, length); |
| 1249 | do { putc(s->window[start++], stderr); } while (--length != 0); |
| 1250 | } |
| 1251 | } |
| 1252 | #else |
| 1253 | # define check_match(s, start, match, length) |
| 1254 | #endif /* DEBUG */ |
no test coverage detected