diff --git a/src/Symfony/Component/Debug/FatalErrorHandler/ClassNotFoundFatalErrorHandler.php b/src/Symfony/Component/Debug/FatalErrorHandler/ClassNotFoundFatalErrorHandler.php index 98418b0497..929ad903eb 100644 --- a/src/Symfony/Component/Debug/FatalErrorHandler/ClassNotFoundFatalErrorHandler.php +++ b/src/Symfony/Component/Debug/FatalErrorHandler/ClassNotFoundFatalErrorHandler.php @@ -150,7 +150,7 @@ class ClassNotFoundFatalErrorHandler implements FatalErrorHandlerInterface */ private function convertFileToClass($path, $file) { - $namespacedClass = str_replace(array($path.'/', '.php', '/'), array('', '', '\\'), $file); + $namespacedClass = str_replace(array($path.DIRECTORY_SEPARATOR, '.php', '/'), array('', '', '\\'), $file); $pearClass = str_replace('\\', '_', $namespacedClass); // We cannot use the autoloader here as most of them use require; but if the class