In moodle/enrol/database/enrol.php, version 1.27, a failure to connect to the database results in a fatal PHP error when an undefined variable is used as an object. $enroldb is known to be undefined by the encapulating if statement around lines 19 through 23.
Suggested change for Line 21:
< error_log('[ENROL_DB] Could not make a connection: '.$enroldb->ErrorMsg());
> error_log('[ENROL_DB] Could not make a connection');