#14655require_once() instead of require() should be used in entry scripts
Description
In showpic.php, index_ts.php, typo3/init.php TYPO3 uses the PHP function require() to include classes like t3lib_div.
Later on in the process, there are some other files included having a line like this:
require_once(PATH_t3lib.‘class.t3lib_div.php’);
Normally the fact that t3lib_div was already included earlier should not cause any problems because require_once() should only include if the class wasn’t already included, but it seems like the behaviour of that function changed in a recent PHP version, so that require_once() now DOES include files which have already been included with require(). The solution would be to change also the FIRST inclusions from require() to require_once().
According to Rupert Germann, this bug only occurs when a PHP accelerator is enabled.
A typical PHP error message resulting from this problem is this:
PHP Fatal error: Cannot redeclare class t3lib_div in /www/htdocs/_data/typo3.com/typo3_src-3.8.0-dev-cvs/t3lib/class.t3lib_div.php on line 209
(issue imported from #M958)
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.