This commit is contained in:
Igor Pavlov
2021-07-22 23:00:14 +01:00
committed by Kornel
parent 4a960640a3
commit 585698650f
619 changed files with 34904 additions and 10859 deletions

View File

@@ -34,7 +34,7 @@ UInt32 CMemBitDecoder::ReadBits(unsigned numBits)
if (numBits <= avail)
{
_bitPos += numBits;
return res | (b >> (avail - numBits)) & ((1 << numBits) - 1);
return res | ((b >> (avail - numBits)) & ((1 << numBits) - 1));
}
numBits -= avail;
res |= (UInt32)(b & ((1 << avail) - 1)) << numBits;