doom_py/src/vizdoom/lzma/C/LzFind.c [587:627]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  UInt32 h2, h3, d2, d3, maxLen, offset, pos;
  UInt32 *hash;
  GET_MATCHES_HEADER(4)

  HASH4_CALC;

  hash = p->hash;
  pos = p->pos;

  d2 = pos - hash[                h2];
  d3 = pos - hash[kFix3HashSize + h3];

  curMatch = hash[kFix4HashSize + hv];

  hash[                h2] = pos;
  hash[kFix3HashSize + h3] = pos;
  hash[kFix4HashSize + hv] = pos;

  maxLen = 0;
  offset = 0;
  
  if (d2 < p->cyclicBufferSize && *(cur - d2) == *cur)
  {
    distances[0] = maxLen = 2;
    distances[1] = d2 - 1;
    offset = 2;
  }
  
  if (d2 != d3 && d3 < p->cyclicBufferSize && *(cur - d3) == *cur)
  {
    maxLen = 3;
    distances[offset + 1] = d3 - 1;
    offset += 2;
    d2 = d3;
  }
  
  if (offset != 0)
  {
    UPDATE_maxLen
    distances[offset - 2] = maxLen;
    if (maxLen == lenLimit)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



doom_py/src/vizdoom/lzma/C/LzFind.c [719:759]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  UInt32 h2, h3, d2, d3, maxLen, offset, pos;
  UInt32 *hash;
  GET_MATCHES_HEADER(4)

  HASH4_CALC;

  hash = p->hash;
  pos = p->pos;
  
  d2 = pos - hash[                h2];
  d3 = pos - hash[kFix3HashSize + h3];
  
  curMatch = hash[kFix4HashSize + hv];

  hash[                h2] = pos;
  hash[kFix3HashSize + h3] = pos;
  hash[kFix4HashSize + hv] = pos;

  maxLen = 0;
  offset = 0;

  if (d2 < p->cyclicBufferSize && *(cur - d2) == *cur)
  {
    distances[0] = maxLen = 2;
    distances[1] = d2 - 1;
    offset = 2;
  }
  
  if (d2 != d3 && d3 < p->cyclicBufferSize && *(cur - d3) == *cur)
  {
    maxLen = 3;
    distances[offset + 1] = d3 - 1;
    offset += 2;
    d2 = d3;
  }
  
  if (offset != 0)
  {
    UPDATE_maxLen
    distances[offset - 2] = maxLen;
    if (maxLen == lenLimit)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



