Merge remote-tracking branch 'origin/QA_4_4' into QA_4_4

This commit is contained in:
Weblate 2015-06-04 18:16:12 +02:00
commit 1decf976ef
3 changed files with 9 additions and 2 deletions

View File

@ -8,6 +8,7 @@ phpMyAdmin - ChangeLog
- bug #4909 central column with multiple server
- bug #4937 Custom export with backquotes off is not working
- bug #4908 Reverse proxy: infinite internal redirect (added warning in doc)
- bug #4942 Export to gzip saves plain text under Chrome
4.4.8.0 (2015-05-28)
- bug Allow accessing visual query builder when pmadb is not configured

View File

@ -709,7 +709,9 @@ function PMA_downloadHeader($filename, $mimetype, $length = 0, $no_cache = true)
header('Content-Type: ' . $mimetype);
// inform the server that compression has been done,
// to avoid a double compression (for example with Apache + mod_deflate)
if (strpos($mimetype, 'gzip') !== false) {
$notChromeOrLessThan43 = PMA_USR_BROWSER_AGENT != 'CHROME' // see bug #4942
|| (PMA_USR_BROWSER_AGENT == 'CHROME' && PMA_USR_BROWSER_VER < 43);
if (strpos($mimetype, 'gzip') !== false && $notChromeOrLessThan43) {
header('Content-Encoding: gzip');
}
header('Content-Transfer-Encoding: binary');

View File

@ -54,10 +54,14 @@ function PMA_gzencodeNeeded()
* and gz compression was not asked via $cfg['OBGzip']
* but transparent compression does not apply when saving to server
*/
$chromeAndGreaterThan43 = PMA_USR_BROWSER_AGENT == 'CHROME'
&& PMA_USR_BROWSER_VER >= 43; // see bug #4942
if (@function_exists('gzencode')
&& ((! @ini_get('zlib.output_compression')
&& ! PMA_isGzHandlerEnabled())
|| $GLOBALS['save_on_server'])
|| $GLOBALS['save_on_server']
|| $chromeAndGreaterThan43)
) {
return true;
} else {