diff options
author | Eugene Kosov <claprix@yandex.ru> | 2019-07-09 13:22:22 +0300 |
---|---|---|
committer | Eugene Kosov <claprix@yandex.ru> | 2019-07-09 13:22:22 +0300 |
commit | 26c389b7b770a3699ec1fc81df7f379f6084c9e6 (patch) | |
tree | 7f915e858b211834deeb52928dfdf5ab12b24bfe /sql | |
parent | b9557418ccd9f484806515fba030757274e691f2 (diff) | |
parent | fd08f953222b854428dc259631e8fc707fe34619 (diff) | |
download | mariadb-git-26c389b7b770a3699ec1fc81df7f379f6084c9e6.tar.gz |
Merge 10.1 into 10.2
Diffstat (limited to 'sql')
-rw-r--r-- | sql/item_sum.cc | 11 | ||||
-rw-r--r-- | sql/rpl_mi.cc | 9 | ||||
-rw-r--r-- | sql/sp_head.cc | 2 | ||||
-rw-r--r-- | sql/sql_plugin.cc | 9 |
4 files changed, 13 insertions, 18 deletions
diff --git a/sql/item_sum.cc b/sql/item_sum.cc index ee53b242c83..5bed0d32009 100644 --- a/sql/item_sum.cc +++ b/sql/item_sum.cc @@ -2703,11 +2703,14 @@ Item_sum_hybrid::min_max_update_str_field() if (!args[0]->null_value) { - result_field->val_str(&cmp->value2); - - if (result_field->is_null() || - (cmp_sign * sortcmp(res_str,&cmp->value2,collation.collation)) < 0) + if (result_field->is_null()) result_field->store(res_str->ptr(),res_str->length(),res_str->charset()); + else + { + result_field->val_str(&cmp->value2); + if ((cmp_sign * sortcmp(res_str,&cmp->value2,collation.collation)) < 0) + result_field->store(res_str->ptr(),res_str->length(),res_str->charset()); + } result_field->set_notnull(); } } diff --git a/sql/rpl_mi.cc b/sql/rpl_mi.cc index e8b76880df4..82a462d742b 100644 --- a/sql/rpl_mi.cc +++ b/sql/rpl_mi.cc @@ -115,15 +115,6 @@ void Master_info::wait_until_free() Master_info::~Master_info() { wait_until_free(); -#ifdef WITH_WSREP - /* - Do not free "wsrep" rpl_filter. It will eventually be freed by - free_all_rpl_filters() when server terminates. - */ - if (strncmp(connection_name.str, STRING_WITH_LEN("wsrep"))) -#endif - rpl_filters.delete_element(connection_name.str, connection_name.length, - (void (*)(const char*, uchar*)) free_rpl_filter); my_free(connection_name.str); delete_dynamic(&ignore_server_ids); mysql_mutex_destroy(&run_lock); diff --git a/sql/sp_head.cc b/sql/sp_head.cc index 027892b8441..0179214e508 100644 --- a/sql/sp_head.cc +++ b/sql/sp_head.cc @@ -191,7 +191,7 @@ sp_get_flags_for_command(LEX *lex) switch (lex->sql_command) { case SQLCOM_SELECT: - if (lex->result) + if (lex->result && !lex->analyze_stmt) { flags= 0; /* This is a SELECT with INTO clause */ break; diff --git a/sql/sql_plugin.cc b/sql/sql_plugin.cc index 29cc4d17c87..19c0f508939 100644 --- a/sql/sql_plugin.cc +++ b/sql/sql_plugin.cc @@ -77,7 +77,7 @@ uint plugin_maturity_map[]= { 0, 1, 2, 3, 4, 5, 6 }; /* - When you ad a new plugin type, add both a string and make sure that the + When you add a new plugin type, add both a string and make sure that the init and deinit array are correctly updated. */ const LEX_STRING plugin_type_names[MYSQL_MAX_PLUGIN_TYPE_NUM]= @@ -3664,7 +3664,7 @@ static int construct_options(MEM_ROOT *mem_root, struct st_plugin_int *tmp, const LEX_STRING plugin_dash = { C_STRING_WITH_LEN("plugin-") }; uint plugin_name_len= strlen(plugin_name); uint optnamelen; - const int max_comment_len= 180; + const int max_comment_len= 255; char *comment= (char *) alloc_root(mem_root, max_comment_len + 1); char *optname; @@ -3698,8 +3698,9 @@ static int construct_options(MEM_ROOT *mem_root, struct st_plugin_int *tmp, options[0].typelib= options[1].typelib= &global_plugin_typelib; strxnmov(comment, max_comment_len, "Enable or disable ", plugin_name, - " plugin. One of: ON, OFF, FORCE (don't start " - "if the plugin fails to load).", NullS); + " plugin. One of: ON, OFF, FORCE (don't start if the plugin" + " fails to load), FORCE_PLUS_PERMANENT (like FORCE, but the" + " plugin can not be uninstalled).", NullS); options[0].comment= comment; /* Allocate temporary space for the value of the tristate. |