here is some of the code ranging from that area and all is fine:


/**
* Init bbcode cache
*
* requires: $this->bbcode_bitfield
* sets: $this->bbcode_cache with bbcode templates needed for bbcode_bitfield
*/
function bbcode_cache_init()
{
global $phpbb_root_path, $template, $user;

if (empty($this->template_filename))
{
$this->template_bitfield = new bitfield($user->theme['bbcode_bitfield']);
$this->template_filename = $phpbb_root_path . 'styles/' . $user->theme['template_path'] . '/template/bbcode.html';

if (!@file_exists($this->template_filename))
{
if (isset($template->orig_tpl_inherits_id) && $template->orig_tpl_inherits_id)
{
$this->template_filename = $phpbb_root_path . 'styles/' . $user->theme['template_inherit_path'] . '/template/bbcode.html';
if (!@file_exists($this->template_filename))
{
trigger_error('The file ' . $this->template_filename . ' is missing.', E_USER_ERROR);
}
}
else
{
trigger_error('The file ' . $this->template_filename . ' is missing.', E_USER_ERROR);
}
}
}

$bbcode_ids = $rowset = $sql = array();

$bitfield = new bitfield($this->bbcode_bitfield);
$bbcodes_set = $bitfield->get_all_set();

foreach ($bbcodes_set as $bbcode_id)
{
if (isset($this->bbcode_cache[$bbcode_id]))
{
// do not try to re-cache it if it's already in
continue;
}
$bbcode_ids[] = $bbcode_id;

if ($bbcode_id > NUM_CORE_BBCODES)
{
$sql[] = $bbcode_id;
}
}