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

Connection lost on wrong CREATE ROLE

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 10.0.7
    • 10.0.8
    • None
    • None

    Description

      MariaDB [test]> CREATE ROLE '';
      ERROR 2013 (HY000): Lost connection to MySQL server during query

      I don't expect this statement to work, but why is connection lost?

      Attachments

        Activity

          elenst Elena Stepanova added a comment - - edited

          That's because it crashes.

          #2  0x00000000008487dd in handle_fatal_signal (sig=11) at 10.0/sql/signal_handler.cc:262
          #3  <signal handler called>
          #4  0x0000000000ec17aa in insert_dynamic (array=0x58, element=0x7ff1a6ffa208) at 10.0/mysys/array.c:89
          #5  0x00000000005e1a46 in add_role_user_mapping (grantee=0x7ff1a896e070, role=0x0) at 10.0/sql/sql_acl.cc:2342
          #6  0x00000000005f5695 in mysql_create_user (thd=0x7ff1b5f4c070, list=..., handle_as_role=true) at 10.0/sql/sql_acl.cc:9169
          #7  0x0000000000668835 in mysql_execute_command (thd=0x7ff1b5f4c070) at 10.0/sql/sql_parse.cc:4038
          #8  0x000000000066eb28 in mysql_parse (thd=0x7ff1b5f4c070, rawbuf=0x7ff1a8822088 "create role ''", length=14, parser_state=0x7ff1a6ffd630) at 10.0/sql/sql_parse.cc:6394
          #9  0x00000000006619e2 in dispatch_command (command=COM_QUERY, thd=0x7ff1b5f4c070, packet=0x7ff1af24c071 "create role ''", packet_length=14) at 10.0/sql/sql_parse.cc:1296
          #10 0x0000000000660d84 in do_command (thd=0x7ff1b5f4c070) at 10.0/sql/sql_parse.cc:993
          #11 0x000000000077a4e5 in do_handle_one_connection (thd_arg=0x7ff1b5f4c070) at 10.0/sql/sql_connect.cc:1379
          #12 0x000000000077a238 in handle_one_connection (arg=0x7ff1b5f4c070) at 10.0/sql/sql_connect.cc:1293
          #13 0x0000000000a9d219 in pfs_spawn_thread (arg=0x7ff1af64cf90) at 10.0/storage/perfschema/pfs.cc:1853
          #14 0x00007ff1d5371b50 in start_thread (arg=<optimized out>) at pthread_create.c:304
          #15 0x00007ff1d3ec0a7d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112

          elenst Elena Stepanova added a comment - - edited That's because it crashes. #2 0x00000000008487dd in handle_fatal_signal (sig=11) at 10.0/sql/signal_handler.cc:262 #3 <signal handler called> #4 0x0000000000ec17aa in insert_dynamic (array=0x58, element=0x7ff1a6ffa208) at 10.0/mysys/array.c:89 #5 0x00000000005e1a46 in add_role_user_mapping (grantee=0x7ff1a896e070, role=0x0) at 10.0/sql/sql_acl.cc:2342 #6 0x00000000005f5695 in mysql_create_user (thd=0x7ff1b5f4c070, list=..., handle_as_role=true) at 10.0/sql/sql_acl.cc:9169 #7 0x0000000000668835 in mysql_execute_command (thd=0x7ff1b5f4c070) at 10.0/sql/sql_parse.cc:4038 #8 0x000000000066eb28 in mysql_parse (thd=0x7ff1b5f4c070, rawbuf=0x7ff1a8822088 "create role ''", length=14, parser_state=0x7ff1a6ffd630) at 10.0/sql/sql_parse.cc:6394 #9 0x00000000006619e2 in dispatch_command (command=COM_QUERY, thd=0x7ff1b5f4c070, packet=0x7ff1af24c071 "create role ''", packet_length=14) at 10.0/sql/sql_parse.cc:1296 #10 0x0000000000660d84 in do_command (thd=0x7ff1b5f4c070) at 10.0/sql/sql_parse.cc:993 #11 0x000000000077a4e5 in do_handle_one_connection (thd_arg=0x7ff1b5f4c070) at 10.0/sql/sql_connect.cc:1379 #12 0x000000000077a238 in handle_one_connection (arg=0x7ff1b5f4c070) at 10.0/sql/sql_connect.cc:1293 #13 0x0000000000a9d219 in pfs_spawn_thread (arg=0x7ff1af64cf90) at 10.0/storage/perfschema/pfs.cc:1853 #14 0x00007ff1d5371b50 in start_thread (arg=<optimized out>) at pthread_create.c:304 #15 0x00007ff1d3ec0a7d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112

          People

            serg Sergei Golubchik
            f_razzoli Federico Razzoli
            Votes:
            0 Vote for this issue
            Watchers:
            3 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.