fixed bug where writeSize could be zero
This commit is contained in:
@@ -548,7 +548,7 @@ static void* outputThread(void* arg)
|
|||||||
}
|
}
|
||||||
{
|
{
|
||||||
// size_t const writeSize = fwrite(job->dst.start, 1, compressedSize, dstFile);
|
// size_t const writeSize = fwrite(job->dst.start, 1, compressedSize, dstFile);
|
||||||
size_t const blockSize = compressedSize >> 7;
|
size_t const blockSize = MAX(compressedSize >> 7, 64 << 10);
|
||||||
size_t pos = 0;
|
size_t pos = 0;
|
||||||
for ( ; ; ) {
|
for ( ; ; ) {
|
||||||
size_t const writeSize = MIN(remaining, blockSize);
|
size_t const writeSize = MIN(remaining, blockSize);
|
||||||
|
|||||||
Reference in New Issue
Block a user