summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 344a6a0)
raw | patch | inline | side by side (parent: 344a6a0)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 16 Jan 2008 16:25:02 +0000 (16:25 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 16 Jan 2008 16:25:02 +0000 (16:25 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8404 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/html/main.php | patch | blob | history | |
gosa-core/include/functions.inc | patch | blob | history |
index be0b728693130d99698fe63fee2c33830f241c3f..dcdd935ad2344ec3a2fd51c79fe2b68300e9d365 100644 (file)
--- a/gosa-core/html/main.php
+++ b/gosa-core/html/main.php
$class_list= get_declared_classes();
foreach ($class_mapping as $class => $path){
if (!in_array($class, $class_list)){
- require_once("$BASE_DIR/$path");
+ if (is_readable("$BASE_DIR/$path")){
+ require_once("$BASE_DIR/$path");
+ } else {
+ echo sprintf(_("Fatal error: cannot locate file '%s' - please run '%s' to fix this"), "$BASE_DIR/$path", "<b>update-gosa</b>");
+ exit;
+ }
}
}
index b1123007da4c49a16803f2ff4fc2a7910b41ea16..50fb2868cc7dc6e0d6db73e9033f5786916c5c52 100644 (file)
if (isset($class_mapping[$class_name])){
require_once($BASE_DIR."/".$class_mapping[$class_name]);
} else {
- echo sprintf(_("Fatal error: cannot load class '%s' - execution aborted"), $class_name);
+ echo sprintf(_("Fatal error: cannot instantiate class '%s' - execution aborted"), $class_name);
print_a(debug_backtrace());
exit;
}
if (!isset($class_mapping[$plugin])){
return false;
} else {
- return file_exists($BASE_DIR."/".$class_mapping[$plugin]);
+ return is_readable($BASE_DIR."/".$class_mapping[$plugin]);
}
}