diff options
author | Oleksandr Byelkin <sanja@mariadb.com> | 2017-11-06 11:23:32 +0100 |
---|---|---|
committer | Oleksandr Byelkin <sanja@mariadb.com> | 2017-11-07 17:39:29 +0100 |
commit | d62ea85e6f6c273a712f951da907ced06f01bc03 (patch) | |
tree | ec7bd9b3b996b5d7582a19f60b3087c1480b9099 /sql/sql_class.cc | |
parent | 2ba1616e5d0f7008d5f6bf2c6cbc439935f6138b (diff) | |
download | mariadb-git-bb-10.3-MDEV-9059.tar.gz |
MDEV-9059: protocol: bundle first command with the authentication packetbb-10.3-MDEV-9059
Diffstat (limited to 'sql/sql_class.cc')
-rw-r--r-- | sql/sql_class.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc index 02f49b6d645..7f0c2e7d891 100644 --- a/sql/sql_class.cc +++ b/sql/sql_class.cc @@ -952,6 +952,8 @@ THD::THD(my_thread_id id, bool is_wsrep_applier) prepare_derived_at_open= FALSE; create_tmp_table_for_derived= FALSE; save_prep_leaf_list= FALSE; + bundle_command.str= NULL; + bundle_command.length= 0; /* Restore THR_THD */ set_current_thd(old_THR_THD); inc_thread_count(); @@ -1364,6 +1366,8 @@ void THD::init(void) #endif //EMBEDDED_LIBRARY apc_target.init(&LOCK_thd_data); + bundle_command.str= NULL; + bundle_command.length= 0; DBUG_VOID_RETURN; } @@ -1486,6 +1490,13 @@ void THD::cleanup(void) DBUG_ENTER("THD::cleanup"); DBUG_ASSERT(cleanup_done == 0); + if (bundle_command.str) + { + my_free(bundle_command.str); + bundle_command.str= 0; + bundle_command.length= 0; + } + set_killed(KILL_CONNECTION); #ifdef ENABLE_WHEN_BINLOG_WILL_BE_ABLE_TO_PREPARE if (transaction.xid_state.xa_state == XA_PREPARED) |