|
Not because of long unique , This test case also fails
CREATE TABLE t1 (b VARCHAR(20) unique, c CHAR(3), d varchar(30) as (c) invisible) ENGINE=MyISAM;
|
create index idx on t1(d);
|
show create table t1;
|
INSERT INTO t1 VALUES ('foo','baz');
|
ALTER TABLE t1 DISABLE KEYS;
|
SET SESSION myisam_repair_threads= 2;
|
--error ER_WRONG_VALUE_COUNT_ON_ROW
|
INSERT INTO t1 SELECT 'qux';
|
|
# Cleanup
|
DROP TABLE t1;
|
|
|
|
I've updated the versions according to the comment above.
Please note however that the test in the comment is not applicable to 10.5, as such index creation is prohibited there (I think the restriction was added in the scope of MDEV-18153 or MDEV-18156, but not entirely sure). However, the original test case applies and fails on 10.5 as well as 10.4.
|
|
Seen this one also, about same testcase.
SET SQL_MODE='';
|
USE test;
|
CREATE TABLE t1 (c1 INT, c2 INT AS (100/c1), KEY(c2)) ENGINE=MyISAM;
|
CREATE TABLE t2 (a INT, b INT, UNIQUE(b)) ENGINE=MyISAM;
|
INSERT INTO t2 VALUES (1,2);
|
SET SESSION MyISAM_REPAIR_THREADS=100;
|
INSERT INTO t1 SELECT * FROM t2;
|
Leads to:
|
10.4.15 eae968f62d285de97ed607c87bc131cd863d5d03 (Debug)
|
mysqld: /test/10.4_dbg/sql/field.cc:4294: virtual longlong Field_long::val_int(): Assertion `!table || table->in_use == _current_thd()' failed.
|
|
10.4.15 eae968f62d285de97ed607c87bc131cd863d5d03 (Debug)
|
Core was generated by `/test/MD110820-mariadb-10.4.15-linux-x86_64-dbg/bin/mysqld --no-defaults --core'.
|
Program terminated with signal SIGABRT, Aborted.
|
#0 __pthread_kill (threadid=<optimized out>, signo=signo@entry=6)
|
at ../sysdeps/unix/sysv/linux/pthread_kill.c:57
|
[Current thread is 1 (Thread 0x145ce87fb700 (LWP 2872556))]
|
(gdb) bt
|
#0 __pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ../sysdeps/unix/sysv/linux/pthread_kill.c:57
|
#1 0x00005631b0f9e8a6 in my_write_core (sig=sig@entry=6) at /test/10.4_dbg/mysys/stacktrace.c:482
|
#2 0x00005631b071acdc in handle_fatal_signal (sig=6) at /test/10.4_dbg/sql/signal_handler.cc:343
|
#3 <signal handler called>
|
#4 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
|
#5 0x0000145d0cd1d8b1 in __GI_abort () at abort.c:79
|
#6 0x0000145d0cd0d42a in __assert_fail_base (fmt=0x145d0ce94a38 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x5631b1209cf8 "!table || table->in_use == _current_thd()", file=file@entry=0x5631b120941c "/test/10.4_dbg/sql/field.cc", line=line@entry=4294, function=function@entry=0x5631b120e300 <Field_long::val_int()::__PRETTY_FUNCTION__> "virtual longlong Field_long::val_int()") at assert.c:92
|
#7 0x0000145d0cd0d4a2 in __GI___assert_fail (assertion=assertion@entry=0x5631b1209cf8 "!table || table->in_use == _current_thd()", file=file@entry=0x5631b120941c "/test/10.4_dbg/sql/field.cc", line=line@entry=4294, function=function@entry=0x5631b120e300 <Field_long::val_int()::__PRETTY_FUNCTION__> "virtual longlong Field_long::val_int()") at assert.c:101
|
#8 0x00005631b06f1dc6 in Field_long::val_int (this=0x145ce6c461c8) at /test/10.4_dbg/sql/field.cc:4294
|
#9 0x00005631b06f12e4 in Field_int::val_decimal (this=0x145ce6c461c8, decimal_value=0x145ce87fa8d8) at /test/10.4_dbg/sql/field.cc:2127
|
#10 0x00005631b0736a07 in Item_field::val_decimal (this=<optimized out>, decimal_value=<optimized out>) at /test/10.4_dbg/sql/item.cc:3198
|
#11 0x00005631b062a4a7 in VDec::set (this=this@entry=0x145ce87fa8d0, item=item@entry=0x145ce6c47118) at /test/10.4_dbg/sql/sql_type.cc:187
|
#12 0x00005631b07a8f13 in VDec2_lazy::VDec2_lazy (b=0x145ce6c47118, a=<optimized out>, this=0x145ce87fa880) at /test/10.4_dbg/sql/sql_type.h:283
|
#13 Item_func_div::decimal_op (this=0x145ce6c47228, decimal_value=0x145ce87fa998) at /test/10.4_dbg/sql/item_func.cc:1486
|
#14 0x00005631b062a890 in VDec_op::VDec_op (this=0x145ce87fa990, item=0x145ce6c47228) at /test/10.4_dbg/sql/sql_type.cc:201
|
#15 0x00005631b062aa85 in Type_handler_decimal_result::Item_func_hybrid_field_type_val_decimal (this=<optimized out>, item=<optimized out>, dec=0x145ce87faa58) at /test/10.4_dbg/sql/sql_type.cc:4732
|
#16 0x00005631b07756d1 in Item_func_hybrid_field_type::val_decimal (this=0x145ce6c47228, dec=0x145ce87faa58) at /test/10.4_dbg/sql/item_func.h:786
|
#17 0x00005631b062a572 in VDec::VDec (this=0x145ce87faa50, item=0x145ce6c47228) at /test/10.4_dbg/sql/sql_type.cc:194
|
#18 0x00005631b074c842 in Item::save_decimal_in_field (this=<optimized out>, field=0x145ce6c462a0, no_conversions=<optimized out>) at /test/10.4_dbg/sql/item.cc:6553
|
#19 0x00005631b06202b8 in Type_handler_decimal_result::Item_save_in_field (this=<optimized out>, item=<optimized out>, field=<optimized out>, no_conversions=<optimized out>) at /test/10.4_dbg/sql/sql_type.cc:3695
|
#20 0x00005631b0736fac in Item::save_in_field (this=0x145ce6c47228, field=0x145ce6c462a0, no_conversions=<optimized out>) at /test/10.4_dbg/sql/item.cc:6573
|
#21 0x00005631b0569893 in TABLE::update_virtual_field (this=this@entry=0x145ce6d82070, vf=0x145ce6c462a0) at /test/10.4_dbg/sql/table.cc:8405
|
#22 0x00005631b0e35b58 in compute_vcols (info=<optimized out>, record=<optimized out>, keynum=<optimized out>) at /test/10.4_dbg/storage/myisam/ha_myisam.cc:707
|
#23 0x00005631b0e3d9e4 in sort_get_next_record (sort_param=sort_param@entry=0x145ce6d6b870) at /test/10.4_dbg/storage/myisam/mi_check.c:3666
|
#24 0x00005631b0e42e31 in sort_key_read (sort_param=0x145ce6d6b870, key=0x145ce7015148) at /test/10.4_dbg/storage/myisam/mi_check.c:3130
|
#25 0x00005631b0e78dc2 in thr_find_all_keys_exec (sort_param=0x145ce6d6b870) at /test/10.4_dbg/storage/myisam/sort.c:448
|
#26 thr_find_all_keys (arg=0x145ce6d6b870) at /test/10.4_dbg/storage/myisam/sort.c:507
|
#27 0x0000145d0dc846db in start_thread (arg=0x145ce87fb700) at pthread_create.c:463
|
#28 0x0000145d0cdfea3f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
|
Bug confirmed present in:
MariaDB: 10.2.34 (dbg), 10.3.25 (dbg), 10.4.15 (dbg), 10.5.6 (dbg)
Bug confirmed not present in:
MariaDB: 10.1.47 (dbg), 10.1.47 (opt), 10.2.34 (opt), 10.3.25 (opt), 10.4.15 (opt), 10.5.6 (opt)
MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.47 (dbg), 5.6.47 (opt), 5.7.29 (dbg), 5.7.29 (opt), 8.0.19 (dbg), 8.0.19 (opt)
|
|
Note that the testcases in this bug all give slightly different stacks. Unique ID's
!table || table->in_use == _current_thd()|SIGABRT|Field_long::val_int|Field_int::val_decimal|Item_field::val_decimal|VDec::set
|
!table || table->in_use == _current_thd()|SIGABRT|Field_string::val_str|Field::val_str|Field::save_in_field_str|Field_str::save_in_field
|
!table || table->in_use == _current_thd()|SIGABRT|Field_string::val_str|Item_field::val_str|Item::val_str|Item_func_hash::val_int
|
!table || table->in_use == _current_thd()|SIGABRT|Field_long::val_int|Item_field::val_int|Item_func_plus::int_op|Item_func_hybrid_field_type::val_int_from_int_op
|
|
|
Another one without UNIQUE key. Let me know if this is a different bug, but it doesn't look to be (myisam_repair_threads).
USE test;
|
SET SQL_MODE='';
|
CREATE TABLE t (a INT);
|
SET myisam_repair_threads=2;
|
INSERT INTO t VALUES (NULL), (1);
|
SELECT * FROM t INTO OUTFILE 'myfile';
|
CREATE TABLE t2 (a INT, b INT GENERATED ALWAYS AS (a+1) VIRTUAL, INDEX (b), CONSTRAINT x FOREIGN KEY(b) REFERENCES t (a)) ENGINE=MyISAM;
|
LOAD DATA INFILE 'myfile' INTO TABLE t2;
|
Leads to:
|
10.5.6 2bac9782aa81ad386beaf00eb126ccf2d15031a1 (Debug)
|
mysqld: /test/10.5_dbg/sql/field.cc:4408: virtual longlong Field_long::val_int(): Assertion `!table || table->in_use == _current_thd()' failed.
|
|
10.5.6 2bac9782aa81ad386beaf00eb126ccf2d15031a1 (Debug)
|
Core was generated by `/test/MD150920-mariadb-10.5.6-linux-x86_64-dbg/bin/mysqld --no-defaults --core-'.
|
Program terminated with signal SIGABRT, Aborted.
|
#0 __pthread_kill (threadid=<optimized out>, signo=signo@entry=6)
|
at ../sysdeps/unix/sysv/linux/pthread_kill.c:57
|
[Current thread is 1 (Thread 0x14ca203ff700 (LWP 4029466))]
|
(gdb) bt
|
#0 __pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ../sysdeps/unix/sysv/linux/pthread_kill.c:57
|
#1 0x000055571a5d285a in my_write_core (sig=sig@entry=6) at /test/10.5_dbg/mysys/stacktrace.c:424
|
#2 0x0000555719d993a9 in handle_fatal_signal (sig=6) at /test/10.5_dbg/sql/signal_handler.cc:330
|
#3 <signal handler called>
|
#4 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
|
#5 0x000014ca432fa8b1 in __GI_abort () at abort.c:79
|
#6 0x000014ca432ea42a in __assert_fail_base (fmt=0x14ca43471a38 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55571a8dc420 "!table || table->in_use == _current_thd()", file=file@entry=0x55571a8dbab3 "/test/10.5_dbg/sql/field.cc", line=line@entry=4408, function=function@entry=0x55571a8e1040 <Field_long::val_int()::__PRETTY_FUNCTION__> "virtual longlong Field_long::val_int()") at assert.c:92
|
#7 0x000014ca432ea4a2 in __GI___assert_fail (assertion=assertion@entry=0x55571a8dc420 "!table || table->in_use == _current_thd()", file=file@entry=0x55571a8dbab3 "/test/10.5_dbg/sql/field.cc", line=line@entry=4408, function=function@entry=0x55571a8e1040 <Field_long::val_int()::__PRETTY_FUNCTION__> "virtual longlong Field_long::val_int()") at assert.c:101
|
#8 0x0000555719d704e2 in Field_long::val_int (this=0x14ca20c58a08) at /test/10.5_dbg/sql/field.cc:4408
|
#9 0x0000555719dbae08 in Item_field::val_int (this=0x14ca20c584a0) at /test/10.5_dbg/sql/item.cc:3269
|
#10 0x0000555719e25c17 in Item_func_plus::int_op (this=0x14ca20c58678) at /test/10.5_dbg/sql/item_func.cc:1111
|
#11 0x0000555719cbc168 in Item_func_hybrid_field_type::val_int_from_int_op (this=<optimized out>) at /test/10.5_dbg/sql/item_func.h:858
|
#12 Type_handler_int_result::Item_func_hybrid_field_type_val_int (this=<optimized out>, item=<optimized out>) at /test/10.5_dbg/sql/sql_type.cc:5342
|
#13 0x0000555719df8716 in Item_func_hybrid_field_type::val_int (this=0x14ca20c58678) at /test/10.5_dbg/sql/item_func.h:914
|
#14 0x0000555719dcf005 in Item::save_int_in_field (this=0x14ca20c58678, field=0x14ca20c58ae0, no_conversions=<optimized out>) at /test/10.5_dbg/sql/item.cc:6656
|
#15 0x0000555719cbeb3e in Type_handler_int_result::Item_save_in_field (this=<optimized out>, item=<optimized out>, field=<optimized out>, no_conversions=<optimized out>) at /test/10.5_dbg/sql/sql_type.cc:4288
|
#16 0x0000555719db813c in Item::save_in_field (this=0x14ca20c58678, field=0x14ca20c58ae0, no_conversions=<optimized out>) at /test/10.5_dbg/sql/item.cc:6666
|
#17 0x0000555719bf8f7b in TABLE::update_virtual_field (this=this@entry=0x14ca20c57588, vf=0x14ca20c58ae0) at /test/10.5_dbg/sql/table.cc:8635
|
#18 0x000055571a5613bb in compute_vcols (info=<optimized out>, record=<optimized out>, keynum=<optimized out>) at /test/10.5_dbg/storage/myisam/ha_myisam.cc:707
|
#19 0x000055571a569808 in sort_get_next_record (sort_param=sort_param@entry=0x14ca20d38088) at /test/10.5_dbg/storage/myisam/mi_check.c:3668
|
#20 0x000055571a56ebc2 in sort_key_read (sort_param=0x14ca20d38088, key=0x14ca210151b3) at /test/10.5_dbg/storage/myisam/mi_check.c:3131
|
#21 0x000055571a5a4793 in thr_find_all_keys_exec (sort_param=0x14ca20d38088) at /test/10.5_dbg/storage/myisam/sort.c:451
|
#22 thr_find_all_keys (arg=0x14ca20d38088) at /test/10.5_dbg/storage/myisam/sort.c:510
|
#23 0x000014ca43fdd6db in start_thread (arg=0x14ca203ff700) at pthread_create.c:463
|
#24 0x000014ca433dba3f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
|
Bug confirmed present in:
MariaDB: 10.2.34 (dbg), 10.3.25 (dbg), 10.4.15 (dbg), 10.5.6 (dbg), 10.6.0 (dbg)
Bug confirmed not present in:
MariaDB: 10.1.47 (dbg), 10.1.47 (opt), 10.2.34 (opt), 10.3.25 (opt), 10.4.15 (opt), 10.5.6 (opt), 10.6.0 (opt)
MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.49 (dbg), 5.6.49 (opt), 5.7.31 (dbg), 5.7.31 (opt), 8.0.21 (dbg), 8.0.21 (opt)
Optimized output:
|
10.5.6 2bac9782aa81ad386beaf00eb126ccf2d15031a1 (Optimized)
|
10.5.6>LOAD DATA INFILE 'myfile' INTO TABLE t2;
|
Query OK, 2 rows affected, 2 warnings (0.002 sec)
|
Records: 2 Deleted: 0 Skipped: 0 Warnings: 2
|
|
10.5.6>show warnings;
|
+---------+------+--------------------------------------------+
|
| Level | Code | Message |
|
+---------+------+--------------------------------------------+
|
| Warning | 1261 | Row 1 doesn't contain data for all columns |
|
| Warning | 1261 | Row 2 doesn't contain data for all columns |
|
+---------+------+--------------------------------------------+
|
2 rows in set (0.000 sec)
|
|
|
Another testcase leading to a new crash on 10.4 (opt) and a slightly different stack on 10.4+ debug.
SET sql_mode='',myisam_repair_threads=100;
|
CREATE TABLE t (a BINARY,b BLOB,c BLOB AS (CONCAT (a,b)),h CHAR,INDEX (c)) ENGINE=InnoDB;
|
INSERT INTO t VALUES (0,0,DEFAULT,0);
|
CREATE TABLE ti LIKE t;
|
ALTER TABLE ti ENGINE=MyISAM;
|
INSERT INTO ti SELECT * FROM t;
|
Leads to:
|
10.4.29 cacea31687c098c0348deb1e433f4baddd817419 (Optimized)
|
Core was generated by `/test/MD110223-mariadb-10.4.29-linux-x86_64-opt/bin/mariadbd --no-defaults --co'.
|
Program terminated with signal SIGSEGV, Segmentation fault.
|
#0 0x00005588a28eaa0b in Item_func_concat::append_value (this=0x14609406acc8,
|
thd=0x0, res=0x14609406acf8, app=0x14609406abd8)
|
at /test/10.4_opt/sql/item_strfunc.cc:688
|
[Current thread is 1 (Thread 0x1460a8349640 (LWP 3592472))]
|
(gdb) bt
|
#0 0x00005588a28eaa0b in Item_func_concat::append_value (this=0x14609406acc8, thd=0x0, res=0x14609406acf8, app=0x14609406abd8) at /test/10.4_opt/sql/item_strfunc.cc:688
|
#1 0x00005588a28eabb6 in Item_func_concat::val_str (this=0x14609406acc8, str=0x14609406acf8) at /test/10.4_opt/sql/item_strfunc.cc:634
|
#2 0x00005588a2861ee2 in Item::save_str_in_field (this=0x14609406acc8, field=0x1460940611c0, no_conversions=<optimized out>) at /test/10.4_opt/sql/item.cc:6674
|
#3 0x00005588a2853317 in Item::save_in_field (this=0x14609406acc8, field=0x1460940611c0, no_conversions=<optimized out>) at /test/10.4_opt/sql/item.cc:6722
|
#4 0x00005588a2717a0e in TABLE::update_virtual_field (this=this@entry=0x146094061328, vf=0x1460940611c0, ignore_warnings=ignore_warnings@entry=false) at /test/10.4_opt/sql/table.cc:8679
|
#5 0x00005588a2cec239 in compute_vcols (info=0x14609406b458, record=<optimized out>, keynum=<optimized out>) at /test/10.4_opt/storage/myisam/ha_myisam.cc:733
|
#6 0x00005588a2cf3e7c in sort_get_next_record (sort_param=sort_param@entry=0x146094065f68) at /test/10.4_opt/storage/myisam/mi_check.c:3670
|
#7 0x00005588a2cf9135 in sort_key_read (sort_param=0x146094065f68, key=0x146098000c70) at /test/10.4_opt/storage/myisam/mi_check.c:3134
|
#8 0x00005588a2d265fb in thr_find_all_keys_exec (sort_param=0x146094065f68) at /test/10.4_opt/storage/myisam/sort.c:449
|
#9 thr_find_all_keys (arg=0x146094065f68) at /test/10.4_opt/storage/myisam/sort.c:507
|
#10 0x00001460f6a5bb43 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
|
#11 0x00001460f6aeda00 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
|
|
11.0.1 f2dc4d4c10ac36a73b5c1eb765352d3aee808d66 (Debug)
|
Core was generated by `/test/MD180223-mariadb-11.0.1-linux-x86_64-dbg/bin/mariadbd --no-defaults --cor'.
|
Program terminated with signal SIGABRT, Aborted.
|
#0 __pthread_kill_implementation (no_tid=0, signo=6, threadid=23208583472704)
|
at ./nptl/pthread_kill.c:44
|
[Current thread is 1 (Thread 0x151bab5fa640 (LWP 3368615))]
|
(gdb) bt
|
#0 __pthread_kill_implementation (no_tid=0, signo=6, threadid=23208583472704) at ./nptl/pthread_kill.c:44
|
#1 __pthread_kill_internal (signo=6, threadid=23208583472704) at ./nptl/pthread_kill.c:78
|
#2 __GI___pthread_kill (threadid=23208583472704, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
|
#3 0x0000151be8377476 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
|
#4 0x0000151be835d7f3 in __GI_abort () at ./stdlib/abort.c:79
|
#5 0x0000151be835d71b in __assert_fail_base (fmt=0x151be8512150 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x55a3a40bca28 "!table || table->in_use == _current_thd()", file=0x55a3a40bb5ab "/test/11.0_dbg/sql/field.cc", line=7559, function=<optimized out>) at ./assert/assert.c:92
|
#6 0x0000151be836ee96 in __GI___assert_fail (assertion=0x55a3a40bca28 "!table || table->in_use == _current_thd()", file=0x55a3a40bb5ab "/test/11.0_dbg/sql/field.cc", line=7559, function=0x55a3a40bd1a0 "virtual String* Field_string::val_str(String*, String*)") at ./assert/assert.c:101
|
#7 0x000055a3a36ccc9a in Field_string::val_str (this=0x151b7c08cd00, val_buffer=<optimized out>, val_ptr=0x151b7c090358) at /test/11.0_dbg/sql/field.cc:7559
|
#8 0x000055a3a370c66e in Item_field::val_str (this=0x151b7c090330, str=0x151b7c09e8b8) at /test/11.0_dbg/sql/item.cc:3345
|
#9 0x000055a3a37cc3e4 in Item_func_concat::val_str (this=0x151b7c09e890, str=0x151b7c09e8b8) at /test/11.0_dbg/sql/item_strfunc.cc:635
|
#10 0x000055a3a3722031 in Item::save_str_in_field (this=0x151b7c09e890, field=0x151b7c090090, no_conversions=<optimized out>) at /test/11.0_dbg/sql/item.cc:6824
|
#11 0x000055a3a3616c9a in Type_handler_string_result::Item_save_in_field (this=<optimized out>, item=<optimized out>, field=<optimized out>, no_conversions=<optimized out>) at /test/11.0_dbg/sql/sql_type.cc:4329
|
#12 0x000055a3a370a7db in Item::save_in_field (this=0x151b7c09e890, field=0x151b7c090090, no_conversions=<optimized out>) at /test/11.0_dbg/sql/item.cc:6872
|
#13 0x000055a3a354530d in TABLE::update_virtual_field (this=this@entry=0x151b7c088608, vf=0x151b7c090090, ignore_warnings=ignore_warnings@entry=false) at /test/11.0_dbg/sql/table.cc:9089
|
#14 0x000055a3a3d20301 in compute_vcols (info=0x151b7c09f828, record=<optimized out>, keynum=<optimized out>) at /test/11.0_dbg/storage/myisam/ha_myisam.cc:734
|
#15 0x000055a3a3d279f9 in sort_get_next_record (sort_param=sort_param@entry=0x151b7c0abe68) at /test/11.0_dbg/storage/myisam/mi_check.c:3672
|
#16 0x000055a3a3d2b1c8 in sort_key_read (sort_param=0x151b7c0abe68, key=0x151b80000d70) at /test/11.0_dbg/storage/myisam/mi_check.c:3135
|
#17 0x000055a3a3d57209 in thr_find_all_keys_exec (sort_param=0x151b7c0abe68) at /test/11.0_dbg/storage/myisam/sort.c:453
|
#18 thr_find_all_keys (arg=0x151b7c0abe68) at /test/11.0_dbg/storage/myisam/sort.c:511
|
#19 0x0000151be83c9b43 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
|
#20 0x0000151be845ba00 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
|
|
|
The last testcase gives a UBSAN issue in optimized builds only:
|
11.0.1 4d09050ca77a7efac4565d46e4bcd85a5f210c53 (Optimized, UBASAN)
|
/test/11.0_opt_san/sql/item_strfunc.cc:698:12: runtime error: member access within null pointer of type 'struct THD'
|
#0 0x559f8df765b3 in Item_func_concat::append_value(THD*, String*, String const*) /test/11.0_opt_san/sql/item_strfunc.cc:698
|
#1 0x559f8df76c8e in Item_func_concat::val_str(String*) /test/11.0_opt_san/sql/item_strfunc.cc:644
|
#2 0x559f8d8d975a in Item::save_str_in_field(Field*, bool) /test/11.0_opt_san/sql/item.cc:6808
|
#3 0x559f8d82c72a in Item::save_in_field(Field*, bool) /test/11.0_opt_san/sql/item.cc:6856
|
#4 0x559f8ca934a7 in TABLE::update_virtual_field(Field*, bool) /test/11.0_opt_san/sql/table.cc:8951
|
#5 0x559f8fb91270 in compute_vcols /test/11.0_opt_san/storage/myisam/ha_myisam.cc:734
|
#6 0x559f8fbc20a9 in sort_get_next_record /test/11.0_opt_san/storage/myisam/mi_check.c:3672
|
#7 0x559f8fbda47b in sort_key_read /test/11.0_opt_san/storage/myisam/mi_check.c:3135
|
#8 0x559f8fd0ce6a in thr_find_all_keys_exec /test/11.0_opt_san/storage/myisam/sort.c:453
|
#9 0x559f8fd0ce6a in thr_find_all_keys /test/11.0_opt_san/storage/myisam/sort.c:511
|
#10 0x14a57a3dbb42 in start_thread nptl/pthread_create.c:442
|
#11 0x14a57a46d9ff (/lib/x86_64-linux-gnu/libc.so.6+0x1269ff)
|
|
230304 16:37:49 [ERROR] mysqld got signal 11 ;
|
|
|
Another testcase leads to a slightly different stack.
SET sql_mode='';
|
SET @@myisam_repair_threads=2;
|
CREATE TABLE t (a VARCHAR(1),va CHAR(1) GENERATED ALWAYS AS (uCASE (a)) VIRTUAL,KEY(va)) ENGINE=MyISAM;
|
INSERT INTO t (a) VALUES (1);
|
CREATE TEMPORARY TABLE t (f INT);
|
DROP TABLE t;
|
REPAIR TABLE t;
|
Leads to
|
10.4.30 6966d7fe4b7ccfb2b7d16ca4d7d5ab08234fa9ec (Debug)
|
mariadbd: /test/10.4_dbg/sql/field.cc:7177: virtual int Field_string::store(const char*, size_t, CHARSET_INFO*): Assertion `!table || table->in_use == _current_thd()' failed.
|
|
10.4.30 6966d7fe4b7ccfb2b7d16ca4d7d5ab08234fa9ec (Debug)
|
Core was generated by `/test/MD220523-mariadb-10.4.30-linux-x86_64-dbg/bin/mariadbd --no-defaults --co'.
|
Program terminated with signal SIGABRT, Aborted.
|
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
|
[Current thread is 1 (Thread 0x147c6d36c700 (LWP 3093025))]
|
(gdb) bt
|
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
|
#1 0x0000147c87eb7859 in __GI_abort () at abort.c:79
|
#2 0x0000147c87eb7729 in __assert_fail_base (fmt=0x147c8804d588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x5611c6ef25c0 "!table || table->in_use == _current_thd()", file=0x5611c6ef120c "/test/10.4_dbg/sql/field.cc", line=7177, function=<optimized out>) at assert.c:92
|
#3 0x0000147c87ec8fd6 in __GI___assert_fail (assertion=assertion@entry=0x5611c6ef25c0 "!table || table->in_use == _current_thd()", file=file@entry=0x5611c6ef120c "/test/10.4_dbg/sql/field.cc", line=line@entry=7177, function=function@entry=0x5611c6ef5050 "virtual int Field_string::store(const char*, size_t, CHARSET_INFO*)") at assert.c:101
|
#4 0x00005611c63fcd86 in Field_string::store (this=0x147c2801fa28, from=0x147c6d36b700 "1", length=1, cs=0x5611c75bc7a0 <my_charset_latin1>) at /test/10.4_dbg/include/my_pthread.h:376
|
#5 0x00005611c6441273 in Item::save_str_in_field (this=0x147c2801eee8, field=0x147c2801fa28, no_conversions=<optimized out>) at /test/10.4_dbg/sql/sql_string.h:291
|
#6 0x00005611c632ee9e in Type_handler_string_result::Item_save_in_field (this=<optimized out>, item=<optimized out>, field=<optimized out>, no_conversions=<optimized out>) at /test/10.4_dbg/sql/sql_type.cc:3821
|
#7 0x00005611c64280d5 in Item::save_in_field (this=0x147c2801eee8, field=0x147c2801fa28, no_conversions=<optimized out>) at /test/10.4_dbg/sql/item.cc:6723
|
#8 0x00005611c6288d40 in TABLE::update_virtual_field (this=this@entry=0x147c280225b8, vf=0x147c2801fa28, ignore_warnings=ignore_warnings@entry=false) at /test/10.4_dbg/sql/table.cc:8649
|
#9 0x00005611c6bae097 in compute_vcols (info=0x147c28024ae8, record=<optimized out>, keynum=<optimized out>) at /test/10.4_dbg/storage/myisam/ha_myisam.cc:733
|
#10 0x00005611c6bb650c in sort_get_next_record (sort_param=sort_param@entry=0x147c281312d8) at /test/10.4_dbg/storage/myisam/mi_check.c:3670
|
#11 0x00005611c6bb9ab8 in sort_key_read (sort_param=0x147c281312d8, key=0x147c18000cf0) at /test/10.4_dbg/storage/myisam/mi_check.c:3134
|
#12 0x00005611c6be5168 in thr_find_all_keys_exec (sort_param=0x147c281312d8) at /test/10.4_dbg/storage/myisam/sort.c:448
|
#13 thr_find_all_keys (arg=0x147c281312d8) at /test/10.4_dbg/storage/myisam/sort.c:507
|
#14 0x0000147c883c8609 in start_thread (arg=<optimized out>) at pthread_create.c:477
|
#15 0x0000147c87fb4133 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
|
Unique ID
!table || table->in_use == _current_thd()|SIGABRT|Field_string::store|Item::save_str_in_field|Type_handler_string_result::Item_save_in_field|Item::save_in_field
|
|
|
Please review bb-10.4-midenok
|