View | Details | Raw Unified
Collapse All | Expand All

(-) inflate.c (-4 / +8 lines)
 Lines 983-988    Link Here 
  unsigned l;           /* last length */
  unsigned l;           /* last length */
  unsigned m;           /* mask for bit lengths table */
  unsigned m;           /* mask for bit lengths table */
  unsigned n;           /* number of lengths to get */
  unsigned n;           /* number of lengths to get */
  struct huft *tlp;     
  struct huft *tl;      /* literal/length code table */
  struct huft *tl;      /* literal/length code table */
  struct huft *td;      /* distance code table */
  struct huft *td;      /* distance code table */
  unsigned bl;          /* lookup bits for tl */
  unsigned bl;          /* lookup bits for tl */
 Lines 996-1001    Link Here 
  int retval = 0;       /* error code returned: initialized to "no error" */
  int retval = 0;       /* error code returned: initialized to "no error" */
  td = tlp = tl = (struct huft *)NULL;
  /* make local bit buffer */
  /* make local bit buffer */
  Trace((stderr, "\ndynamic block"));
  Trace((stderr, "\ndynamic block"));
  b = G.bb;
  b = G.bb;
 Lines 1047-1055    Link Here 
  while (i < n)
  while (i < n)
  {
  {
    NEEDBITS(bl)
    NEEDBITS(bl)
    j = (td = tl + ((unsigned)b & m))->b;
    j = (tlp = tl + ((unsigned)b & m))->b;
    DUMPBITS(j)
    DUMPBITS(j)
    j = td->v.n;
    j = tlp->v.n;
    if (j < 16)                 /* length of code in bits (0..15) */
    if (j < 16)                 /* length of code in bits (0..15) */
      ll[i++] = l = j;          /* save last length in l */
      ll[i++] = l = j;          /* save last length in l */
    else if (j == 16)           /* repeat last length 3 to 6 times */
    else if (j == 16)           /* repeat last length 3 to 6 times */
 Lines 1141-1146    Link Here 
      huft_free(td);
      huft_free(td);
    }
    }
    huft_free(tl);
    huft_free(tl);
    return retval;
    return retval;
  }
  }
 Lines 1149-1156    Link Here 
cleanup_and_exit:
cleanup_and_exit:
  /* free the decoding tables, return */
  /* free the decoding tables, return */
  huft_free(tl);
  if (tl) huft_free(tl);
  huft_free(td);
  if (td) huft_free(td);
  return retval;
  return retval;
}
}