Download & Extend

Mysqli: PHP errors when database connection fails

Project:Drupal core
Version:5.x-dev
Component:base system
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

When the database connection fails for any reason, database.mysqli.inc uses mysqli_error() to retrieve the error message, which results in PHP warnings because mysqli_error() can't be used this way. The correct function to use is mysqli_connect_error() as done in HEAD.

Patch attached.

AttachmentSizeStatusTest resultOperations
20080113.core-mysqli-connect-error.patch2.04 KBIgnored: Check issue status.NoneNone

Comments

#1

Status:needs review» fixed

Committed to 5.x.

#2

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.