Branch Coverage

deps/libgit2/deps/zlib/inftrees.c
Criterion Covered Total %
branch 46 76 60.5


line true false branch
107 20064 1254 for (len = 0; len <= MAXBITS; len++)
109 129196 1254 for (sym = 0; sym < codes; sym++)
114 13738 0 for (max = MAXBITS; max >= 1; max--)
115 1254 12484 if (count[max] != 0) break;
116 1254 0 if (root > max) root = max;
117 0 1254 if (max == 0) { /* no symbols to code at all */
126 3266 26 for (min = 1; min < max; min++)
127 1228 2038 if (count[min] != 0) break;
128 0 1254 if (root < min) root = min;
132 18810 1254 for (len = 1; len <= MAXBITS; len++) {
135 0 18810 if (left < 0) return -1; /* over-subscribed */
137 0 1254 if (left > 0 && (type == CODES || max != 1))
0 0 if (left > 0 && (type == CODES || max != 1))
0 0 if (left > 0 && (type == CODES || max != 1))
142 17556 1254 for (len = 1; len < MAXBITS; len++)
146 129196 1254 for (sym = 0; sym < codes; sym++)
147 26170 103026 if (lens[sym] != 0) work[offs[lens[sym]]++] = (unsigned short)sym;
209 418 836 if ((type == LENS && used > ENOUGH_LENS) ||
418 0 if ((type == LENS && used > ENOUGH_LENS) ||
418 836 if ((type == LENS && used > ENOUGH_LENS) ||
210 0 418 (type == DISTS && used > ENOUGH_DISTS))
217 21493 4677 if (work[sym] + 1U < match) {
221 4259 418 else if (work[sym] >= match) {
237 52180 26170 } while (fill != 0);
241 24916 26170 while (huff & incr)
243 24916 1254 if (incr != 0) {
252 4288 21882 if (--(count[len]) == 0) {
253 1254 3034 if (len == max) break;
258 0 24916 if (len > root && (huff & mask) != low) {
0 0 if (len > root && (huff & mask) != low) {
260 0 0 if (drop == 0)
269 0 0 while (curr + drop < max) {
271 0 0 if (left <= 0) break;
278 0 0 if ((type == LENS && used > ENOUGH_LENS) ||
0 0 if ((type == LENS && used > ENOUGH_LENS) ||
0 0 if ((type == LENS && used > ENOUGH_LENS) ||
279 0 0 (type == DISTS && used > ENOUGH_DISTS))
293 0 1254 if (huff != 0) {