[Pkg-owncloud-commits] [owncloud] 91/394: Fix remote.php CSS+JS garbish on some systems

David Prévot taffit at alioth.debian.org
Fri Nov 8 23:11:34 UTC 2013


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to annotated tag v4.5.10
in repository owncloud.

commit 66343f977faf8185487be6a0e35d68d647c5cba7
Author: Arthur Schiwon <blizzz at owncloud.com>
Date:   Wed Nov 14 12:53:36 2012 +0100

    Fix remote.php CSS+JS garbish on some systems
---
 lib/minimizer.php |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/lib/minimizer.php b/lib/minimizer.php
index d50ab0d..79aede1 100644
--- a/lib/minimizer.php
+++ b/lib/minimizer.php
@@ -33,6 +33,12 @@ abstract class OC_Minimizer {
 			$cache->set($cache_key.'.gz', $gzout);
 			OC_Response::setETagHeader($etag);
 		}
+		// on some systems (e.g. SLES 11, but not Ubuntu) mod_deflate and zlib compression will compress the output twice. 
+		// This results in broken core.css and  core.js. To avoid it, we switch off zlib compression.
+		// Since mod_deflate is still active, Apache will compress what needs to be compressed, i.e. no disadvantage.
+		if(function_exists('apache_setenv') && ini_get('zlib.output_compression')) {
+                        ini_set('zlib.output_compression', 'Off');
+                }
 		if ($encoding = OC_Request::acceptGZip()) {
 			header('Content-Encoding: '.$encoding);
 			$out = $gzout;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git



More information about the Pkg-owncloud-commits mailing list