Skip to content

Commit a59f483

Browse files
committed
MDEV-28092 MariaDB SEGV issue
add test
1 parent 5aef012 commit a59f483

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

mysql-test/suite/vcol/r/vcol_misc.result

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -510,6 +510,17 @@ a b
510510
13 14
511511
DROP TABLE t1;
512512
SET sql_mode=DEFAULT;
513+
create table t1 (b timestamp, a int as (1 in (dayofmonth (b between 'x' and current_user) = b)));
514+
insert into t1(b) values ('2022-03-17 14:55:37');
515+
select 1 from t1 x natural join t1;
516+
1
517+
1
518+
Warnings:
519+
Warning 1292 Incorrect datetime value: 'x'
520+
Warning 1292 Incorrect datetime value: 'root@localhost'
521+
Warning 1292 Incorrect datetime value: 'x'
522+
Warning 1292 Incorrect datetime value: 'root@localhost'
523+
drop table t1;
513524
#
514525
# End of 10.2 tests
515526
#

mysql-test/suite/vcol/t/vcol_misc.test

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,14 @@ SELECT * FROM t1;
488488
DROP TABLE t1;
489489
SET sql_mode=DEFAULT;
490490

491+
#
492+
# MDEV-28092 MariaDB SEGV issue
493+
#
494+
create table t1 (b timestamp, a int as (1 in (dayofmonth (b between 'x' and current_user) = b)));
495+
insert into t1(b) values ('2022-03-17 14:55:37');
496+
select 1 from t1 x natural join t1;
497+
drop table t1;
498+
491499
--echo #
492500
--echo # End of 10.2 tests
493501
--echo #

0 commit comments

Comments
 (0)