Commit b4074069 authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

MDEV-26657 : Initialize some fields in create_background_thd()

Avoid reading uninitialized memory by  thd_get_error_context_description().
Note, that THD::real_id can't be initialized at this stage, so it will be zeroed.
parent 699de65d
......@@ -4922,6 +4922,9 @@ MYSQL_THD create_background_thd()
thd->set_command(COM_DAEMON);
thd->system_thread= SYSTEM_THREAD_GENERIC;
thd->security_ctx->host_or_ip= "";
thd->real_id= 0;
thd->thread_id= 0;
thd->query_id= 0;
return thd;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment