summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2018-02-06 17:09:26 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2018-02-06 17:09:26 +0200
commit560b9895d413bdfedda0a0ca871a635858990c05 (patch)
treee801eb6dc9d198bcb048d3a734bc6e3d77b0858e
parentb4db96da5848e41bd15eafbecffaac71c465d1b6 (diff)
downloadmariadb-git-560b9895d413bdfedda0a0ca871a635858990c05.tar.gz
MDEV-15115 Assertion failure in CREATE SEQUENCE...ROW_FORMAT=REDUNDANT
dict_tf_is_valid(): Allow no-rollback tables in ROW_FORMAT=REDUNDANT.
-rw-r--r--mysql-test/suite/sql_sequence/create.result7
-rw-r--r--mysql-test/suite/sql_sequence/create.test8
-rw-r--r--storage/innobase/include/dict0dict.ic2
3 files changed, 16 insertions, 1 deletions
diff --git a/mysql-test/suite/sql_sequence/create.result b/mysql-test/suite/sql_sequence/create.result
index 20d16822575..6af43a3faa4 100644
--- a/mysql-test/suite/sql_sequence/create.result
+++ b/mysql-test/suite/sql_sequence/create.result
@@ -634,3 +634,10 @@ create temporary table s (i int);
drop temporary sequence s;
ERROR 42S02: Unknown SEQUENCE: 'test.s'
drop table s;
+#
+# MDEV-15115 Assertion failure in CREATE SEQUENCE...ROW_FORMAT=REDUNDANT
+#
+CREATE SEQUENCE seq1 ENGINE=InnoDB ROW_FORMAT=REDUNDANT;
+DROP SEQUENCE seq1;
+CREATE TEMPORARY SEQUENCE seq1 ENGINE=InnoDB ROW_FORMAT=REDUNDANT;
+DROP TEMPORARY SEQUENCE seq1;
diff --git a/mysql-test/suite/sql_sequence/create.test b/mysql-test/suite/sql_sequence/create.test
index 91411bebfde..65c0641eab9 100644
--- a/mysql-test/suite/sql_sequence/create.test
+++ b/mysql-test/suite/sql_sequence/create.test
@@ -450,3 +450,11 @@ create temporary table s (i int);
--error ER_UNKNOWN_SEQUENCES
drop temporary sequence s;
drop table s;
+
+--echo #
+--echo # MDEV-15115 Assertion failure in CREATE SEQUENCE...ROW_FORMAT=REDUNDANT
+--echo #
+CREATE SEQUENCE seq1 ENGINE=InnoDB ROW_FORMAT=REDUNDANT;
+DROP SEQUENCE seq1;
+CREATE TEMPORARY SEQUENCE seq1 ENGINE=InnoDB ROW_FORMAT=REDUNDANT;
+DROP TEMPORARY SEQUENCE seq1;
diff --git a/storage/innobase/include/dict0dict.ic b/storage/innobase/include/dict0dict.ic
index dde3e2bfac7..4efb0971209 100644
--- a/storage/innobase/include/dict0dict.ic
+++ b/storage/innobase/include/dict0dict.ic
@@ -667,7 +667,7 @@ dict_tf_is_valid(
bit. For ROW_FORMAT=REDUNDANT, only the DATA_DIR flag
(which we cleared above) can be set. If any other flags
are set, the flags are invalid. */
- return(flags == 0);
+ return(flags == 0 || flags == DICT_TF_MASK_NO_ROLLBACK);
}
return(dict_tf_is_valid_not_redundant(flags));