Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-25400

Error message including Unicode changed on MariaDB 10.5

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Not a Bug
    • 10.5.9
    • N/A
    • Character Sets
    • None

    Description

      On the MariaDB 10.5, call the function mysql_send_query with the query "\345\306}\037" to test the error message from the MariaDB server.

      523	  rv = mysql_send_query(args->mysql, args->sql_ptr, args->sql_len);
      (gdb) i lo
      args = 0x7fffffffd980
      rv = 32767
      (gdb) p *args
      $1 = {mysql = 0x5555559e6060, sql = 93824997035680, sql_ptr = 0x5555559e8eb0 "\345\306}\037", 
        sql_len = 4, wrapper = 0x555555907900}
      

      and call the function mysql_read_query_result.

       my_bool res = mysql_read_query_result(client); 
      

      And the result is here.

      (gdb) p res
      $2 = 1 '\001'
      (gdb) p (*client).net.last_error
      $3 = "You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '??}\\001F' at line 1", '\000' <repeats 355 times>
      

      On the MariaDB 10.5 The error message is

      You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '??}\\001F' at line 1
      

      But on MariaDB <= 10.4 the error message is

      You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '??}\u001F' at line 1
      

      On MariaDB 10.5,

      \\001F
      

      vs

      On MariaDB <= 10.4,

      \u001F
      

      Did you change something on MariaDB about the error message? Is it a specification or bug?

      Here is the context. We found the issue on MariaDB Ruby binding.
      https://github.com/brianmario/mysql2/issues/1152#issuecomment-818463242

      Thank you.

      Attachments

        Activity

          People

            serg Sergei Golubchik
            junaruga Jun Aruga
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.