Index: includes/path.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/path.inc,v retrieving revision 1.19.2.1 diff -u -p -r1.19.2.1 path.inc --- includes/path.inc 13 Oct 2008 21:06:41 -0000 1.19.2.1 +++ includes/path.inc 7 Jun 2009 10:47:12 -0000 @@ -217,9 +217,15 @@ function drupal_set_title($title = NULL) * Boolean value: TRUE if the current page is the front page; FALSE if otherwise. */ function drupal_is_front_page() { - // As drupal_init_path updates $_GET['q'] with the 'site_frontpage' path, - // we can check it against the 'site_frontpage' variable. - return $_GET['q'] == drupal_get_normal_path(variable_get('site_frontpage', 'node')); + static $is_front_page; + + if (!isset($is_front_page)) { + // As drupal_init_path updates $_GET['q'] with the 'site_frontpage' path, + // we can check it against the 'site_frontpage' variable. + $is_front_page = ($_GET['q'] == drupal_get_normal_path(variable_get('site_frontpage', 'node'))); + } + + return $is_front_page; } /**