lib/storage: fix 32-bit builds for GOARH=386 or GOARCH=arm

This commit is contained in:
Aliaksandr Valialkin 2020-09-29 12:40:35 +03:00
parent 0b0259c42c
commit ef416c72c2

View file

@ -348,7 +348,7 @@ func (b *Block) UnmarshalPortable(src []byte) ([]byte, error) {
return src, fmt.Errorf("cannot unmarshal rowsCount: %w", err)
}
if rowsCount > math.MaxUint32 {
return src, fmt.Errorf("got too big rowsCount=%d; it mustn't exceed %d", rowsCount, math.MaxUint32)
return src, fmt.Errorf("got too big rowsCount=%d; it mustn't exceed %d", rowsCount, uint32(math.MaxUint32))
}
b.bh.RowsCount = uint32(rowsCount)
src, scale, err := encoding.UnmarshalVarInt64(src)