summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <sanja@askmonty.org>2014-11-17 17:13:30 +0100
committerunknown <sanja@askmonty.org>2014-11-17 17:13:30 +0100
commit4d882329a998b7955cf164b5ff687e623d25bbb5 (patch)
treedc18758f285309ba290738108bef94b2e18d7214 /mysql-test
parente9fc98b5838c06356209196384e37a11e8e3c058 (diff)
downloadmariadb-git-4d882329a998b7955cf164b5ff687e623d25bbb5.tar.gz
MDEV-7116: Dynamic column hangs/segfaults
Going to 'create_new_string:' caused double freeing alloc_plan (there and at 'end:').
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/dyncol.result22
-rw-r--r--mysql-test/t/dyncol.test26
2 files changed, 48 insertions, 0 deletions
diff --git a/mysql-test/r/dyncol.result b/mysql-test/r/dyncol.result
index 4753728793a..cc4e8074395 100644
--- a/mysql-test/r/dyncol.result
+++ b/mysql-test/r/dyncol.result
@@ -1777,5 +1777,27 @@ group_concat(cast(column_json(dyn) as char))
{"name1":"value1","name2":"value2"}
drop table t1;
#
+# MDEV-7116: Dynamic column hangs/segfaults
+#
+create table t1 (
+impressions mediumblob
+);
+insert into t1 values ("");
+update t1
+set impressions = column_add(impressions,
+'total', 12,
+'2014-10-28 16:00:00', 3,
+'2014-10-30 15:00:00', 3,
+'2014-11-04 09:00:00', 6
+);
+update t1
+set impressions = column_add(impressions,
+'total', "a12",
+'2014-10-28 16:00:00', "a3",
+'2014-10-30 15:00:00', "a3",
+'2014-11-04 09:00:00', "a6"
+ );
+drop table t1;
+#
# end of 10.0 tests
#
diff --git a/mysql-test/t/dyncol.test b/mysql-test/t/dyncol.test
index c5d442ebe49..65a94dcb49e 100644
--- a/mysql-test/t/dyncol.test
+++ b/mysql-test/t/dyncol.test
@@ -839,5 +839,31 @@ select group_concat(cast(column_json(dyn) as char)) from t1;
drop table t1;
--echo #
+--echo # MDEV-7116: Dynamic column hangs/segfaults
+--echo #
+create table t1 (
+ impressions mediumblob
+);
+
+insert into t1 values ("");
+
+update t1
+set impressions = column_add(impressions,
+ 'total', 12,
+ '2014-10-28 16:00:00', 3,
+ '2014-10-30 15:00:00', 3,
+ '2014-11-04 09:00:00', 6
+ );
+update t1
+set impressions = column_add(impressions,
+ 'total', "a12",
+ '2014-10-28 16:00:00', "a3",
+ '2014-10-30 15:00:00', "a3",
+ '2014-11-04 09:00:00', "a6"
+ );
+
+drop table t1;
+
+--echo #
--echo # end of 10.0 tests
--echo #