php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #61443 Since upgrade to PHP 5.4, we can't change zlib.output_compression on the fly.
Submitted: 2012-03-19 19:48 UTC Modified: 2012-04-24 18:44 UTC
Votes:2
Avg. Score:5.0 ± 0.0
Reproduced:2 of 2 (100.0%)
Same Version:2 (100.0%)
Same OS:2 (100.0%)
From: debian at ange7 dot com Assigned: mike (profile)
Status: Closed Package: Zlib related
PHP Version: 5.4.0 OS: Debian Sid
Private report: No CVE-ID: None
 [2012-03-19 19:48 UTC] debian at ange7 dot com
Description:
------------
Package: php5
Version: 5.4.0-2
Severity: important

Since upgrade to PHP 5.4, we can't change zlib.output_compression on the 
fly.

Test script:
---------------
<?php
if (!headers_sent())
    ini_set('zlib.output_compression', true);
echo 'end';
?>

Expected result:
----------------
end

Actual result:
--------------
Warning: ini_set(): Cannot enable zlib.output_compression - there has 
already been output in /home/alex/workspace/test/www/nouveauScript.php 
on line 3
end

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-03-19 21:32 UTC] [email protected]
Cannot reproduce. Are you sure about your reproduce script?
 [2012-03-19 21:32 UTC] [email protected]
-Status: Open +Status: Feedback -Assigned To: +Assigned To: mike
 [2012-03-19 21:36 UTC] [email protected]
-Package: PHP options/info functions +Package: Zlib related
 [2012-03-20 10:07 UTC] debian at ange7 dot com
code to reproduce :

<?php 
ob_start(); echo "foo\n"; ob_get_clean(); 
if(!headers_sent()) ini_set('zlib.output_compression', true); echo "end\n";
 [2012-03-20 10:07 UTC] debian at ange7 dot com
-Status: Feedback +Status: Assigned
 [2012-04-24 18:44 UTC] [email protected]
This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.


 [2012-04-24 18:44 UTC] [email protected]
-Status: Assigned +Status: Closed
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Fri Jun 27 05:01:39 2025 UTC