Only use titlefile if it is actually there and readable

This commit is contained in:
Gina Haeussge
2010-01-17 12:47:37 +01:00
parent 1bf1bc0512
commit 89486f7bc6

View File

@@ -608,7 +608,7 @@ class syntax_plugin_filelist extends DokuWiki_Syntax_Plugin {
if (!$params['direct']) {
$mid = str_replace('/', ':', substr($titlefile, strlen($this->mediadir)));
$perm = auth_quickaclcheck($mid);
if ($perm >= AUTH_READ) {
if (is_readable($titlefile) && $perm >= AUTH_READ) {
$filename = io_readFile($titlefile, false);
}
} else {