diff --git a/libraries/error_report.lib.php b/libraries/error_report.lib.php index bcc997e3ef..e84e7141ed 100644 --- a/libraries/error_report.lib.php +++ b/libraries/error_report.lib.php @@ -156,7 +156,11 @@ function PMA_sanitizeUrl($url) // get script name preg_match("<([a-zA-Z\-_\d]*\.php)$>", $components["path"], $matches); - $script_name = $matches[1]; + if (count($matches)) < 2) { + $script_name = 'index.php'; + } else { + $script_name = $matches[1]; + } // remove deployment specific details to make uri more generic parse_str($components["query"], $query_array);