MDL-35168 fix yui combo path disclosure
This commit is contained in:
+2
-1
@@ -115,7 +115,8 @@ foreach ($parts as $part) {
|
||||
$contentfile = "$CFG->libdir/yuilib/$part";
|
||||
}
|
||||
if (!file_exists($contentfile) or !is_file($contentfile)) {
|
||||
$content .= "\n// Combo resource $part ($contentfile) not found!\n";
|
||||
$location = '$CFG->dirroot'.preg_replace('/^'.preg_quote($CFG->dirroot, '/').'/', '', $contentfile);
|
||||
$content .= "\n// Combo resource $part ($location) not found!\n";
|
||||
continue;
|
||||
}
|
||||
$filecontent = file_get_contents($contentfile);
|
||||
|
||||
Reference in New Issue
Block a user