Index: includes/common.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/common.inc,v retrieving revision 1.602 diff -u -r1.602 common.inc --- includes/common.inc 15 Dec 2006 07:47:08 -0000 1.602 +++ includes/common.inc 5 Jan 2007 20:30:38 -0000 @@ -349,8 +349,10 @@ menu_set_active_item(''); } - if (empty($return)) { + if (empty($return) || $return == MENU_NOT_FOUND || $return == MENU_ACCESS_DENIED) { drupal_set_title(t('Page not found')); + menu_set_active_item(''); + $return = t('The requested page could not be found.'); } // To conserve CPU and bandwidth, omit the blocks print theme('page', $return, FALSE); @@ -378,8 +380,9 @@ menu_set_active_item(''); } - if (empty($return)) { + if (empty($return) || $return == MENU_NOT_FOUND || $return == MENU_ACCESS_DENIED) { drupal_set_title(t('Access denied')); + menu_set_active_item(''); $return = t('You are not authorized to access this page.'); } print theme('page', $return);