php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #19436 zlib.output_compression causing corruption
Submitted: 2002-09-16 08:23 UTC Modified: 2003-09-22 06:49 UTC
Votes:9
Avg. Score:4.1 ± 0.6
Reproduced:9 of 9 (100.0%)
Same Version:1 (11.1%)
Same OS:1 (11.1%)
From: steveh at brendata dot co dot uk Assigned:
Status: No Feedback Package: Zlib related
PHP Version: 4.3.3 OS: redhat linux 7.3
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: steveh at brendata dot co dot uk
New email:
PHP Version: OS:

 

 [2002-09-16 08:23 UTC] steveh at brendata dot co dot uk
When using php to supply data for a file download from a database the resultant file is shortened, switching off output_compression resolves this issue.

Had to update to the latest CVS version to fix truncation issues on 4.2.3 of text fields.

Using code very similar to that listed on the sybase functions page (search for hex2bin)

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-01-07 07:14 UTC] steveh at brendata dot co dot uk
This is still happening with php 4.3.0 and zend optimiser 2.0.3, I turned zlib.output_compression=on, tested and the downloaded file (a zip file) was corrupt, set zlib.output_compression=off and then the download worked fine.
 [2003-09-17 11:57 UTC] steveh at brendata dot co dot uk
Still a problem with 4.3.3
 [2003-09-17 11:58 UTC] steveh at brendata dot co dot uk
Should also mention that this is with the latest version of the zend optimiser as well.
 [2003-09-17 13:48 UTC] sr@php.net
Does it work without the Zend Optimiser?

If the file is still corrupted after turning off Zend Optimiser, can you give us a short self contained example php script (and a file) which shows the error?

Thank you!
 [2003-09-22 06:49 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 [2003-11-26 09:36 UTC] luis-oliveira at iol dot pt
I?m experiencing that bug too.

Linux, PHP 4.3.3, no Zend Optimizer.
When using php to supply data for a file download from a database, if the file to download is a zip file, the downloaded file gets corrupted. If i switch zlib.output_compression to off in php.ini, the problem no longer exists.

I guess this could be sorted by detecting a ZIP content-type and switching zlib.output_compression off dinamically (as it is now being done for the image type).
 [2011-08-08 01:31 UTC] danialhorton at hotmail dot com
can't believe this bug still occurs to this day.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 06 03:01:29 2024 UTC