From 304e95a3337b9e961feab77fe36ace9e0cd57401 Mon Sep 17 00:00:00 2001 From: Giuseppe Lavagetto Date: Wed, 29 Jul 2015 12:12:55 +0200 Subject: [PATCH] Add Content-Length header to thumb.php redirects Without the Content-Length header, the response is sent with Transfer-Encoding: Chunked, which is somehow mangled by mod_fastcgi. Varnish then claims the response is malformed and declines to process it, sending the client a 503 instead. This is a followup of 0ee9e717f49b9e15bd63fd66f3d0967939c35b05 Bug: T84842 Change-Id: Ia610a43789e6ff14cfc0964f285bbec39c890152 --- thumb.php | 1 + 1 file changed, 1 insertion(+) diff --git a/thumb.php b/thumb.php index 3b7ff43612..03a3f354e6 100644 --- a/thumb.php +++ b/thumb.php @@ -213,6 +213,7 @@ function wfStreamThumb( array $params ) { if ( count( $varyHeader ) ) { $response->header( 'Vary: ' . implode( ', ', $varyHeader ) ); } + $response->header( 'Content-Length: 0' ); return; } -- 2.20.1