Commit 703a5ef1 authored by Igor Babaev's avatar Igor Babaev Committed by Vladislav Vaintroub

MDEV-19351 statistics_for_command_is_needed: Conditional jump or move

           depends on uninitialised value

Initialized THD::force_read_stats introduced in the patch for MDEV-17605.
Leaving this field uninitialized in the constructor of the THD class may
trigger reading statistical data that is not needed.
parent 4c995eb1
...@@ -863,6 +863,7 @@ THD::THD(my_thread_id id, bool is_wsrep_applier, bool skip_global_sys_var_lock) ...@@ -863,6 +863,7 @@ THD::THD(my_thread_id id, bool is_wsrep_applier, bool skip_global_sys_var_lock)
invoker.init(); invoker.init();
prepare_derived_at_open= FALSE; prepare_derived_at_open= FALSE;
create_tmp_table_for_derived= FALSE; create_tmp_table_for_derived= FALSE;
force_read_stats= FALSE;
save_prep_leaf_list= FALSE; save_prep_leaf_list= FALSE;
org_charset= 0; org_charset= 0;
/* Restore THR_THD */ /* Restore THR_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