Permalink
Browse files

Correctly handle failing case

Issue #11953

Signed-off-by: Michal Čihař <michal@cihar.com>
  • Loading branch information...
nijel committed Feb 12, 2016
1 parent 38aba04 commit 9d1a5997cb6c2c9a6a2594fce6190fb63c74f53b
Showing with 4 additions and 4 deletions.
  1. +4 −4 libraries/Error.class.php
@@ -425,17 +425,17 @@ public function isUserError()
* prevent path disclosure in error message,
* and make users feel safe to submit error reports
*
* @param string $dest path to be shorten
* @param string $path path to be shorten
*
* @return string shortened path
*/
public static function relPath($dest)
public static function relPath($path)
{
$dest = @realpath($dest);
$dest = @realpath($path);
/* Probably affected by open_basedir */
if ($dest === FALSE) {
return $dest;
return $path;
}
$Ahere = explode(

0 comments on commit 9d1a599

Please sign in to comment.