|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2010-08-23 17:52 UTC] denis at bitrix dot ru
-Status: Open
+Status: Closed
[2010-08-23 17:52 UTC] denis at bitrix dot ru
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 05 02:00:01 2025 UTC |
Description: ------------ The last 4 bytes in GZIP file must contain the size of uncompressed data. When you write in append mode, php writes just the size of the last chunk. Test script: --------------- <? $str = '0123456789'; // 10 bytes $f = gzopen('tmp.gz','w'); gzwrite($f, $str); gzclose($f); $f = gzopen('tmp.gz','a'); gzwrite($f, $str); gzclose($f); ?> # gzip -l tmp.gz Expected result: ---------------- uncompressed 20 Actual result: -------------- uncompressed 10