[BUGFIX] Scheduler BE module fails to load due to autoloader issues
authorTolleiv Nietsch <info@tolleiv.de>
Wed, 8 Feb 2012 07:51:13 +0000 (08:51 +0100)
committerChristian Kuhn <lolli@schwarzbu.ch>
Sat, 18 Feb 2012 11:52:55 +0000 (12:52 +0100)
When displaying a list of tasks, scheduler unserializes exceptions.
If the exception class is not known to the autoloader, PHP will
return an instance of _PHP_Incomplete_Class. This instance is
tested for to prevent a fatal error.

Change-Id: Ifc8c90787ada60af6b5892f67dc7adf6d90e916d
Resolves: #33116
Releases: 4.7, 4.6, 4.5
Reviewed-on: http://review.typo3.org/8897
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
typo3/sysext/scheduler/mod1/index.php

index 2b53678..b8bcc5e 100755 (executable)
@@ -1147,7 +1147,7 @@ class tx_scheduler_Module extends t3lib_SCbase {
                                                        // Try to get the stored exception object
                                                $exception = unserialize($schedulerRecord['lastexecution_failure']);
                                                        // If the exception could not be unserialized, issue a default error message
-                                               if ($exception === FALSE) {
+                                               if ($exception === FALSE  || ($exception instanceof __PHP_Incomplete_Class)) {
                                                        $failureDetail = $GLOBALS['LANG']->getLL('msg.executionFailureDefault');
                                                } else {
                                                        $failureDetail = sprintf($GLOBALS['LANG']->getLL('msg.executionFailureReport'), $exception->getCode(), $exception->getMessage());