mirror of
https://github.com/cuberite/libdeflate.git
synced 2025-09-18 08:49:39 -04:00
gzip: allow compressing empty files
This commit is contained in:
parent
8d0a43ac2e
commit
2b047b097b
@ -291,6 +291,11 @@ err:
|
||||
int
|
||||
map_file_contents(struct file_stream *strm, u64 size)
|
||||
{
|
||||
if (size == 0) {
|
||||
strm->mmap_size = 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (size > SIZE_MAX) {
|
||||
msg("%"TS" is too large to be processed by this program",
|
||||
strm->name);
|
||||
|
Loading…
x
Reference in New Issue
Block a user