From e2d5eb67a16ad858a738e9c6d1766c7b59386947 Mon Sep 17 00:00:00 2001 From: Alexey Botchkov Date: Fri, 26 Mar 2021 11:03:40 +0400 Subject: [PATCH] MDEV-25263 JSON_TABLE: json_table test fails with valgrind. Field reset added. --- sql/json_table.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sql/json_table.cc b/sql/json_table.cc index 27a6a130a54..e80e4bce891 100644 --- a/sql/json_table.cc +++ b/sql/json_table.cc @@ -722,10 +722,7 @@ bool Create_json_table::finalize(THD *thd, TABLE *table, m_null_count & 7); m_null_count+= (field->field_length & 7); } - /* - Here we'd call the field->reset(), but we're doing it later - in Table_function_json_table::setup as we define charsets there. - */ + field->reset(); /* Test if there is a default field value. The test for ->ptr is to skip