From d50e99c9f63d3cd46fdde0e95072117759c7e852 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 7 Sep 2009 15:13:58 +0200 Subject: [PATCH] Fix that thd->query_plan_flags was not initialised prior to executing non-query commands (also fixes a Valgrind warning in Buildbot). --- sql/sql_parse.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index 3f2fcbac2c8..761fac5a2eb 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -975,6 +975,7 @@ bool dispatch_command(enum enum_server_command command, THD *thd, the slow log only if opt_log_slow_admin_statements is set. */ thd->enable_slow_log= TRUE; + thd->query_plan_flags= QPLAN_INIT; thd->lex->sql_command= SQLCOM_END; /* to avoid confusing VIEW detectors */ thd->set_time(); VOID(pthread_mutex_lock(&LOCK_thread_count));