Fix rare PclZip/realpath/PHP version problem
In PHP 5.4.4 realpath() handles absolute paths correctly, but in PHP 5.3.8 returns false.
This commit is contained in:
parent
38d3d7be20
commit
d57606082d
|
|
@ -218,7 +218,10 @@ class ZipArchive
|
|||
{
|
||||
/** @var \PclZip $zip Type hint */
|
||||
$zip = $this->zip;
|
||||
$filename = realpath($filename);
|
||||
$test_filename = realpath($filename);
|
||||
if($test_filename !== false) {
|
||||
$filename = $test_filename;
|
||||
}
|
||||
$filenameParts = pathinfo($filename);
|
||||
$localnameParts = pathinfo($localname);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue