From 9d1a5997cb6c2c9a6a2594fce6190fb63c74f53b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 12 Feb 2016 14:16:43 +0100 Subject: [PATCH] Correctly handle failing case MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Issue #11953 Signed-off-by: Michal Čihař --- libraries/Error.class.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libraries/Error.class.php b/libraries/Error.class.php index e8d04ed0e942..089cdbf667d2 100644 --- a/libraries/Error.class.php +++ b/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(