[TYPO3-core] RFC #14117: RuntimeException thrown within the exception handler when wrong database credentials

Patrick Broens patrick at netcreators.com
Thu Apr 15 09:56:22 CEST 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

This is an SVN patch request.

Type: Bugfix

Bugtracker References:
http://bugs.typo3.org/view.php?id=14117

Branches:
Trunk

Problem:
With patch 0014061: Do not die, be the exception!, most of the die()
functions are replaced with proper exceptions.

When the database credentials are wrong, a RuntimeException is thrown in
class t3lib_db, function connectDB(). The exception handler itself tries
to connect to the database as well, in
t3lib_error_AbstractExceptionHandler function writeLogEntries(), using
this same function connectDB(), for storage in the devlog and sys_log
table. This causes recurring RuntimeExceptions, which leads to a Fatal
error: Exception thrown without a stack frame in Unknown on line 0

Solution:
Wrap the part in t3lib_error_AbstractExceptionHandler >
writeLogEntries() which handles the database actions in a try/catch
block, where the catch is simply empty.

How to reproduce:
Go to the 1-2-3 installer, use database credentials which are not valid
in the first step and click on 'Continue'.

Cheers

Patrick
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkvGxqYACgkQNgvIvIQSN/yNEACeLutAQfV2sKMlHbUjmmzj2ehw
RFwAnRmcP+5xYN+Pf6ymIQfspusR7ynD
=ffEy
-----END PGP SIGNATURE-----
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20100415_RFC_14117.diff
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20100415/15b8390c/attachment.asc>


More information about the TYPO3-team-core mailing list