Skip to content

Commit

Permalink
fix: correctly resize BitArrays when setBytes is called
Browse files Browse the repository at this point in the history
  • Loading branch information
hello-adam committed May 13, 2021
1 parent f18ad3b commit 5611e18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hobbits-core/bitarray.cpp
Expand Up @@ -417,7 +417,7 @@ void BitArray::set(qint64 i, bool value)
void BitArray::setBytes(qint64 byteOffset, const char *src, qint64 srcByteOffset, qint64 length)
{
if (sizeInBytes() < byteOffset + length) {
resize(byteOffset + length);
resize((byteOffset + length) * 8);
}

QMutexLocker lock(&m_mutex);
Expand Down

0 comments on commit 5611e18

Please sign in to comment.