Skip to content

Commit 9b89c52

Browse files
author
Grahame Grieve
committed
fix gzip related issues
1 parent d8be251 commit 9b89c52

File tree

3 files changed

+2
-253
lines changed

3 files changed

+2
-253
lines changed

dependencies/zflate/zflate.pas

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ tgzipinfo = record
7979

8080
var
8181
zchunkmaxsize: dword = 1024*128; //128 KB default max chunk size
82-
zbuffersize: dword = 1024*1024*4; //4 MB default buffer size
82+
zbuffersize: dword = 1024*1024*16; //16 MB default buffer size
8383

8484
threadvar
8585
zlasterror: integer;

dependencies/zflate/zflatefiles.pas

Lines changed: 0 additions & 251 deletions
This file was deleted.

library/fsl/fsl_gzip.pas

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function gzip(bytes : TBytes; header : boolean; level: dword=9) : TBytes;
5656
function ungzip(bytes : TBytes) : TBytes;
5757
begin
5858
result := zflate.zdecompress(bytes);
59-
if length(result) = 0 then
59+
if zlastError <> 0 then
6060
raise EFslException.create('Failed to read compressed content: '+zflatetranslatecode(zlasterror));
6161
end;
6262

0 commit comments

Comments
 (0)