Index: typo3/mod/tools/em/class.em_index.php =================================================================== --- typo3/mod/tools/em/class.em_index.php (révision 4592) +++ typo3/mod/tools/em/class.em_index.php (copie de travail) @@ -3139,8 +3139,9 @@ $extList = t3lib_div::get_dirs($path); if (is_array($extList)) { foreach($extList as $extKey) { - if (@is_file($path.$extKey.'/ext_emconf.php')) { - $emConf = $this->includeEMCONF($path.$extKey.'/ext_emconf.php', $extKey); + $filename = $path.$extKey.'/ext_emconf.php'; + if (@is_file($filename)) { + $emConf = $this->includeEMCONF($filename, $extKey); if (is_array($emConf)) { if (is_array($list[$extKey])) { $list[$extKey]=array('doubleInstall'=>$list[$extKey]['doubleInstall']); @@ -3152,6 +3153,10 @@ $this->setCat($cat,$list[$extKey], $extKey); } + } else { + if ($extKey != '.svn' && $extKey != 'CVS') { + debug ($filename, $filename.' not found.', __LINE__, __FILE__); + } } } } @@ -5251,7 +5256,7 @@ * @return array EMconf array values. */ function includeEMCONF($path,$_EXTKEY) { - @include($path); + include($path); if(is_array($EM_CONF[$_EXTKEY])) { return $this->fixEMCONF($EM_CONF[$_EXTKEY]); } Index: t3lib/class.t3lib_extmgm.php =================================================================== --- t3lib/class.t3lib_extmgm.php (révision 4592) +++ t3lib/class.t3lib_extmgm.php (copie de travail) @@ -135,6 +135,23 @@ } /** + * Displays an error message if the SYS displayErrors is > 0. Call this before every die function to inform about the reason. + * + * @param string error info + * @return void + */ + function displayErrors($errortext='') { + $displayErrors = (isset($GLOBALS['TYPO3_CONF_VARS']['SYS']['displayErrors']) ? $GLOBALS['TYPO3_CONF_VARS']['SYS']['displayErrors'] : 0); + if ($displayErrors > 0) { + if ($errortext != '') { + t3lib_div::debug(array('error message:' => $errortext)); + } + $tmp = debug_backtrace(); + t3lib_div::debug($tmp); + } + } + + /** * Returns the absolute path to the extension with extension key $key * If the extension is not loaded the function will die with an error message * Useful for internal fileoperations @@ -147,8 +164,9 @@ public static function extPath($key, $script = '') { global $TYPO3_LOADED_EXT; if (!isset($TYPO3_LOADED_EXT[$key])) { - #debug(array(debug_backtrace())); - die('TYPO3 Fatal Error: Extension key "'.$key.'" was NOT loaded! (t3lib_extMgm::extPath)'); + $errorText = 'TYPO3 Fatal Error: Extension key "'.$key.'" was NOT loaded! (t3lib_extMgm::extPath)'; + t3lib_extMgm::displayErrors($errorText); + die($errorText); } return PATH_site.$TYPO3_LOADED_EXT[$key]['siteRelPath'].$script; } @@ -165,7 +183,9 @@ public static function extRelPath($key) { global $TYPO3_LOADED_EXT; if (!isset($TYPO3_LOADED_EXT[$key])) { - die('TYPO3 Fatal Error: Extension key "'.$key.'" was NOT loaded! (t3lib_extMgm::extRelPath)'); + $errorText = 'TYPO3 Fatal Error: Extension key "'.$key.'" was NOT loaded! (t3lib_extMgm::extRelPath)'; + t3lib_extMgm::displayErrors($errorText); + die($errorText); } return $TYPO3_LOADED_EXT[$key]['typo3RelPath']; }