diff options
author | Monty <monty@mariadb.org> | 2022-11-09 19:11:08 +0200 |
---|---|---|
committer | Sergei Petrunia <sergey@mariadb.com> | 2023-02-03 10:34:49 +0300 |
commit | 6418c24c9498a28b3320d26309964203327ae66e (patch) | |
tree | 0403eb51fb12be2c45d2608421e625dd3b4efe9f /sql/sql_acl.cc | |
parent | 0ba47126f1f28d4731b6774d8c526d9d8e55652f (diff) | |
download | mariadb-git-6418c24c9498a28b3320d26309964203327ae66e.tar.gz |
Set thd->query() for internal (startup) transactions
This helps with debugging as 'Query: ' in DBUG traces will show something
useful, for internal transactions, instead of just "".
Diffstat (limited to 'sql/sql_acl.cc')
-rw-r--r-- | sql/sql_acl.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sql/sql_acl.cc b/sql/sql_acl.cc index 1ba056ff89e..5ed1c344cd0 100644 --- a/sql/sql_acl.cc +++ b/sql/sql_acl.cc @@ -2533,6 +2533,8 @@ bool acl_init(bool dont_read_acl_tables) DBUG_RETURN(1); /* purecov: inspected */ thd->thread_stack= (char*) &thd; thd->store_globals(); + thd->set_query_inner((char*) STRING_WITH_LEN("intern:acl_init"), + default_charset_info); /* It is safe to call acl_reload() since acl_* arrays and hashes which will be freed there are global static objects and thus are initialized @@ -8001,6 +8003,9 @@ bool grant_init() DBUG_RETURN(1); /* purecov: deadcode */ thd->thread_stack= (char*) &thd; thd->store_globals(); + thd->set_query_inner((char*) STRING_WITH_LEN("intern:grant_init"), + default_charset_info); + return_val= grant_reload(thd); delete thd; DBUG_RETURN(return_val); |