Fix calculation of compressed size in bytes (#534)

An integer division in the compression:Base:getSize() was being done,
which led to rounding down instead of up.

Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
This commit is contained in:
Daniel Carvalho
2023-11-07 13:58:32 -03:00
committed by GitHub
parent 71973b386e
commit 10374f2f05

View File

@@ -78,7 +78,7 @@ Base::CompressionData::getSizeBits() const
std::size_t
Base::CompressionData::getSize() const
{
return std::ceil(_size/8);
return std::ceil(_size/(float)CHAR_BIT);
}
Base::Base(const Params &p)