|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-03-21 09:45 UTC] aharvey@php.net
-Status: Open
+Status: Bogus
[2011-03-21 09:45 UTC] aharvey@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 15:00:01 2025 UTC |
Description: ------------ PHP is compiled with the following options: System => Linux serv01.testmachine.com 2.6.28.5-grsec-sg2 #6 SMP Fri Feb 20 02:45:11 CST 2009 i686 Build Date => Mar 21 2011 10:04:49 Configure Command => './configure' '--prefix=/usr/local/php52' '--mandir=/usr/man' '--with-config-file-path=/usr/local/php52/lib' '--with-config-file-scan-dir=/usr/local/php52/etc' '--with-pear=/usr/local/php52/pear' '--with-litespeed' '--enable-discard-path' '--enable-sigchild' '--disable-fastcgi' '--enable-magic-quotes' '--with-db4' '--disable-force-cgi-redirect' '--disable-ipv6' '--with-openssl' '--with-zlib' '--with-zlib-dir' '--enable-bcmath' '--with-bz2' '--enable-calendar' '--with-curl' '--with-curlwrappers' '--enable-exif' '--enable-ftp' '--with-kerberos' '--with-gd' '--with-pspell' '--with-libedit' '--with-jpeg-dir' '--with-png-dir' '--with-xpm-dir' '--with-freetype-dir' '--with-t1lib' '--enable-gd-native-ttf' '--with-ttf' '--with-gettext' '--with-imap' '--with-imap-ssl' '--with-ldap' '--with-ldap-sasl' '--enable-mbstring' '--with-mcrypt' '--with-mhash' '--with-mysql' '--with-mysql-sock=/var/lib/mysql/mysql.sock' '--with-mysqli' '--with-ncurses' '--enable-pcntl' '--with-pdo-mysql' '--with-pdo-pgsql' '--with-pgsql' '--with-readline' '--enable-shmop' '--with-snmp=shared' '--enable-ucd-snmp-hack' '--enable-soap' '--enable-sockets' '--enable-sqlite-utf8' '--enable-wddx' '--with-tidy' '--with-xmlrpc' '--enable-zip' '--with-xsl=/usr' '--with-libxml-dir=/usr' '--enable-zend-multibyte' In the master php.ini file zlib.output_compression is set to off as reported by phpinfo(); zlib.output_compression => Off => Off Many applications are using the code shown in the test script to initiate the compression of their headers. With PHP 5.2.17 from the stable repo (snaps too!) return false on the following line: $r = @ini_set('zlib.output_compression', 'On'); Even it is returning false zlib.output_compression is actually enabled and when it reaches ob_start('ob_gzhandler'); because of the false results the following error is produced: [21-Mar-2011 03:18:43] PHP Warning: ob_start() [<a href='ref.outcontrol'>ref.outcontrol</a>]: output handler 'ob_gzhandler' conflicts with 'zlib output compression' in /home/jeepchic/public_html/header.php on line 767 Test case script I provided here works just fine on PHP 5.2.9. Test script: --------------- <? if (function_exists('gzopen')) { $r = @ini_set('zlib.output_compression', 'On'); $r2 = @ini_set('zlib.output_compression_level', '3'); if (!$r || !$r2) { echo "Fail\n"; ob_start('ob_gzhandler'); } else { echo "success\n"; } } else { echo "Fallback\n"; ob_start('ob_gzhandler'); } ?> Expected result: ---------------- echo "success\n"; Actual result: -------------- echo "Fail\n";