Author: zorba-mediawiki-bugzilla
Description:
FastCGI spits out log errors similar to "[error] [client 1.2.3.4] FastCGI: comm with server "/var/www/fastcgi/php-cgi" aborted: error parsing headers: duplicate header 'Status'" when attempting to display a MediaWiki error page, also causing 500 internal server errors for the user. This is because FastCGI+PHP is significantly stricter about headers than base Apache is, and does not like it when you set Status explicitly.
- oldglobfunc.php 2007-11-26 18:55:20.000000000 +0000
+++ GlobalFunctions.php 2007-11-26 18:55:29.000000000 +0000
@@ -1144,7 +1144,6 @@
global $wgOut; $wgOut->disable(); header( "HTTP/1.0 $code $label" );
- header( "Status: $code $label" ); $wgOut->sendCacheControl();
header( 'Content-type: text/html; charset=utf-8' );
This fixes it. I do not know if it has unfortunate side effects on other platforms or with other libraries.
To duplicate: set up FastCGI with PHP, install MediaWiki, do something to generate an error page. This bug won't trigger without an actual MediaWiki error page - in my case it was a circular redirect caused by $wgUsePathInfo being off.
Let me know if I can provide better information somehow.
Version: 1.18.x
Severity: normal
OS: Linux
Platform: PC