Fix some warnings.
This commit is contained in:
@@ -22,8 +22,8 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
namespace NStream{
|
||||
|
||||
CInByte::CInByte(UINT32 aBufferSize):
|
||||
m_BufferSize(aBufferSize),
|
||||
m_BufferBase(0)
|
||||
m_BufferBase(0),
|
||||
m_BufferSize(aBufferSize)
|
||||
{
|
||||
m_BufferBase = new BYTE[m_BufferSize];
|
||||
}
|
||||
|
||||
@@ -24,7 +24,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
namespace NLength {
|
||||
|
||||
const int kNumPosStatesBitsMax = 4;
|
||||
const UINT32 kNumPosStatesBitsMax = 4;
|
||||
const int kNumPosStatesMax = (1 << kNumPosStatesBitsMax);
|
||||
|
||||
|
||||
|
||||
@@ -62,7 +62,7 @@ protected:
|
||||
m_State.Init();
|
||||
m_PreviousByte = 0;
|
||||
m_PeviousIsMatch = false;
|
||||
for(int i = 0 ; i < kNumRepDistances; i++)
|
||||
for(UINT32 i = 0 ; i < kNumRepDistances; i++)
|
||||
m_RepDistances[i] = 0;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -105,7 +105,7 @@ HRESULT CDecoder::Init(ISequentialInStream *anInStream,
|
||||
|
||||
// m_RepMatchLenDecoder.Init();
|
||||
|
||||
for (i = 0; i < kNumLenToPosStates; i++)
|
||||
for (i = 0; (UINT32) i < kNumLenToPosStates; i++)
|
||||
m_PosSlotDecoder[i].Init();
|
||||
|
||||
for(i = 0; i < kNumPosModels; i++)
|
||||
@@ -133,7 +133,7 @@ HRESULT CDecoder::CodeReal(ISequentialInStream *anInStream,
|
||||
bool aPeviousIsMatch = false;
|
||||
BYTE aPreviousByte = 0;
|
||||
UINT32 aRepDistances[kNumRepDistances];
|
||||
for(int i = 0 ; i < kNumRepDistances; i++)
|
||||
for(UINT32 i = 0 ; i < kNumRepDistances; i++)
|
||||
aRepDistances[i] = 0;
|
||||
|
||||
UINT64 aNowPos64 = 0;
|
||||
@@ -144,7 +144,7 @@ HRESULT CDecoder::CodeReal(ISequentialInStream *anInStream,
|
||||
while(aNowPos64 < aNext)
|
||||
{
|
||||
UINT32 aPosState = UINT32(aNowPos64) & m_PosStateMask;
|
||||
if (m_MainChoiceDecoders[aState.m_Index][aPosState].Decode(&m_RangeDecoder) == kMainChoiceLiteralIndex)
|
||||
if (m_MainChoiceDecoders[aState.m_Index][aPosState].Decode(&m_RangeDecoder) == (UINT32) kMainChoiceLiteralIndex)
|
||||
{
|
||||
// aCounts[0]++;
|
||||
aState.UpdateChar();
|
||||
@@ -166,7 +166,7 @@ HRESULT CDecoder::CodeReal(ISequentialInStream *anInStream,
|
||||
aPeviousIsMatch = true;
|
||||
UINT32 aDistance, aLen;
|
||||
if(m_MatchChoiceDecoders[aState.m_Index].Decode(&m_RangeDecoder) ==
|
||||
kMatchChoiceRepetitionIndex)
|
||||
(UINT32) kMatchChoiceRepetitionIndex)
|
||||
{
|
||||
if(m_MatchRepChoiceDecoders[aState.m_Index].Decode(&m_RangeDecoder) == 0)
|
||||
{
|
||||
@@ -218,10 +218,10 @@ HRESULT CDecoder::CodeReal(ISequentialInStream *anInStream,
|
||||
aState.UpdateMatch();
|
||||
UINT32 aPosSlot = m_PosSlotDecoder[GetLenToPosState(aLen)].Decode(&m_RangeDecoder);
|
||||
// aCounts[aPosSlot]++;
|
||||
if (aPosSlot >= kStartPosModelIndex)
|
||||
if (aPosSlot >= (UINT32) kStartPosModelIndex)
|
||||
{
|
||||
aDistance = kDistStart[aPosSlot];
|
||||
if (aPosSlot < kEndPosModelIndex)
|
||||
if (aPosSlot < (UINT32) kEndPosModelIndex)
|
||||
aDistance += m_PosDecoders[aPosSlot - kStartPosModelIndex].Decode(&m_RangeDecoder);
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user