Quantcast
Channel: Piwik Forums - Support & Bugs
Viewing all articles
Browse latest Browse all 4243

PHP 5.5.11 issue (no replies)

$
0
0
Piwik 2.1.0 (and 2.2.0) is not fully compatible with php 5.5.11 due to the following PHP issue http://grokbase.com/t/php/php-bugs/144855dssm/php-bug-bug-67043-new-substr-compare-falsely-reports-equality-on-negative-offset.

The following files are impacted: ProxyHttp.php, StylesheetUIAssetMerger.php, ZipArchive.php and EndsWith.php

There is a workaround that consists of adding the length parameter to the substr_compare function. Can you confirm its implementation in the sub-mentioned files ?

ProxyHttp
if (substr_compare(PHP_SAPI, '-fcgi', -5, 5)) {
StylesheetUIAssetMerger
if ($rootDirectory != '/' && substr_compare($rootDirectory, '/', -1, 1)) {
ZipArchive
if (substr_compare($pathExtracted, '/', -1, 1))
EndsWith
$compiler
            ->raw('(0 === substr_compare(')
            ->subcompile($this->getNode('left'))
            ->raw(', ')
            ->subcompile($this->getNode('right'))
            ->raw(', -strlen(')
            ->subcompile($this->getNode('right'))
            ->raw('), strlen(')
            ->subcompile($this->getNode('right'))
            ->raw(')))')
;

Viewing all articles
Browse latest Browse all 4243

Trending Articles