Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-19505

CRM_Core_Error checks incorrect mysql_error

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.7.12
    • Fix Version/s: 4.7.13
    • Component/s: Core CiviCRM
    • Labels:
    • Documentation Required?:
      None
    • Funding Source:
      Core Team Funds

      Description

      When a SQL error arises, CRM_Core_Error::handle() attempts to look up details using a low-level MySQL API. The code tries to detect "mysql" or "mysqli", but the check is wrong, which should produce two different errors:

      • In PHP 7.x sites, it should crash due to the unrecognized function.
      • In PHP 5.x sites, it should fail to report the actual error message (because it may check the wrong function).

        Attachments

          Activity

            People

            • Assignee:
              timotten Tim Otten
              Reporter:
              timotten Tim Otten
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: