Fix by Anthem to not leak titles

This commit is contained in:
Garvin Hicking 2008-07-22 08:35:27 +00:00
parent cf12fe3fa6
commit bcf3a1bf65
2 changed files with 9 additions and 0 deletions

View File

@ -3,6 +3,9 @@
Version 1.4 ()
------------------------------------------------------------------------
* Do not show title of entries marked as public/private when
viewed without permissions. Patch thanks to Anthem
* Make cookie deletion routine use the same host like cookie
insertion, thanks to JPhilip

View File

@ -48,6 +48,12 @@ if ($serendipity['smarty_raw_mode']) {
if (!is_array($entry) || count($entry) < 1) {
unset($serendipity['GET']['id']);
$entry = array(array());
$serendipity['head_title'] = htmlspecialchars($serendipity['blogTitle']);
$serendipity['head_subtitle'] = '';
$serendipity['smarty']->assign('head_title', $serendipity['head_title']);
$serendipity['smarty']->assign('head_subtitle', $serendipity['head_subtitle']);
$serendipity['view'] = '404';
serendipity_header('HTTP/1.0 404 Not found');
}
serendipity_printEntries($entry, 1);