From d3b2228fd8b9ba13f8adedfee144d222b32b1cec Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Sat, 20 Apr 2019 12:13:42 +0200 Subject: cleanup: cosmetic fixes --- mysql-test/r/func_gconcat.result | 1 - mysql-test/t/func_gconcat.test | 3 --- mysys/tree.c | 2 +- sql/item_sum.h | 8 ++++---- sql/sql_class.h | 1 + 5 files changed, 6 insertions(+), 9 deletions(-) diff --git a/mysql-test/r/func_gconcat.result b/mysql-test/r/func_gconcat.result index 9014450bef3..5c4a2900a80 100644 --- a/mysql-test/r/func_gconcat.result +++ b/mysql-test/r/func_gconcat.result @@ -1,4 +1,3 @@ -drop table if exists t1, t2; create table t1 (grp int, a bigint unsigned, c char(10) not null, d char(10) not null); insert into t1 values (1,1,"a","a"); insert into t1 values (2,2,"b","a"); diff --git a/mysql-test/t/func_gconcat.test b/mysql-test/t/func_gconcat.test index 3cc244339d3..8f6a600a509 100644 --- a/mysql-test/t/func_gconcat.test +++ b/mysql-test/t/func_gconcat.test @@ -1,9 +1,6 @@ # # simple test of group_concat function # ---disable_warnings -drop table if exists t1, t2; ---enable_warnings create table t1 (grp int, a bigint unsigned, c char(10) not null, d char(10) not null); insert into t1 values (1,1,"a","a"); diff --git a/mysys/tree.c b/mysys/tree.c index 9e69ed9a4db..83be0a0d20f 100644 --- a/mysys/tree.c +++ b/mysys/tree.c @@ -224,7 +224,7 @@ TREE_ELEMENT *tree_insert(TREE *tree, void *key, uint key_size, { uint alloc_size; if (tree->flag & TREE_ONLY_DUPS) - return((TREE_ELEMENT *) 1); + return TREE_ELEMENT_UNIQUE; alloc_size=sizeof(TREE_ELEMENT)+key_size+tree->size_of_element; tree->allocated+=alloc_size; diff --git a/sql/item_sum.h b/sql/item_sum.h index d6ccfeb8529..dc672486bce 100644 --- a/sql/item_sum.h +++ b/sql/item_sum.h @@ -1479,8 +1479,8 @@ public: enum Sumfunctype sum_func () const {return GROUP_CONCAT_FUNC;} const char *func_name() const { return "group_concat"; } - virtual Item_result result_type () const { return STRING_RESULT; } - virtual Field *make_string_field(TABLE *table); + Item_result result_type () const { return STRING_RESULT; } + Field *make_string_field(TABLE *table); enum_field_types field_type() const { if (too_big_for_varchar()) @@ -1522,8 +1522,8 @@ public: String* val_str(String* str); Item *copy_or_same(THD* thd); void no_rows_in_result() {} - virtual void print(String *str, enum_query_type query_type); - virtual bool change_context_processor(uchar *cntx) + void print(String *str, enum_query_type query_type); + bool change_context_processor(uchar *cntx) { context= (Name_resolution_context *)cntx; return FALSE; } }; diff --git a/sql/sql_class.h b/sql/sql_class.h index 2517f5cc06f..c0dc42deefe 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -36,6 +36,7 @@ #include "violite.h" /* vio_is_connected */ #include "thr_lock.h" /* thr_lock_type, THR_LOCK_DATA, THR_LOCK_INFO */ #include "thr_timer.h" +#include #include "sql_digest_stream.h" // sql_digest_state -- cgit v1.2.1