#56257Call to a member function qstr() on a non-object
Description
Hello TYPO3 team,
installing TYPO3 with an Oracle database (oci8) fails on certain points. After passing the credentials, the installation crashes with a fatal error:
> PHP Fatal error: Call to a member function qstr() on a non-object in typo3/sysext/dbal/Classes/Database/DatabaseConnection.php on line 1882
At this point, $this->handlerInstance is an empty array. The property is filled in the method handler_init($handlerKey). As far as I understood the code, $cfgArray is a merged array from [‘DB’] and [‘EXTCONF’][‘dbal’][‘handlerCfg’][‘_DEFAULT’] as defined in LocalConfiguration.php. But under certain circumstances, the merge is not complete and the following condition matches, resulting an empty array:
if (!$cfgArray['config']['database']) {
// Configuration is incomplete
return;
}
When putting the DB configuration into the dbal configuration, the bug does not occur:
'EXTCONF' => array(
'dbal' => array(
'handlerCfg' => array(
'_DEFAULT' => array(
'config' => array(
'driver' => 'oci8',
'driverOptions' => array(
'connectSID' => '',
),
'database' => 'typo3',
'host' => 'localhost:1521',
'password' => '*****',
'username' => 'johndoe',
),
'type' => 'adodb',
),
),
),
),