[MDEV-22732] AddressSanitizer: use-after-poison upon update after an error with SIMULTANEOUS_ASSIGNMENT Created: 2020-05-27  Updated: 2023-08-07

Status: Confirmed
Project: MariaDB Server
Component/s: Data Manipulation - Update
Affects Version/s: 10.3, 10.4, 10.5, 10.6, 10.7
Fix Version/s: 10.4, 10.5, 10.6

Type: Bug Priority: Major
Reporter: Elena Stepanova Assignee: Oleksandr Byelkin
Resolution: Unresolved Votes: 0
Labels: None

Issue Links:
Relates
relates to MDEV-16694 Memory leak with EXPLAIN UPDATE, cras... Confirmed
relates to MDEV-22600 Various ASAN use-after-poison errors ... Confirmed
relates to MDEV-31866 Various ASAN use-after-poison errors ... Confirmed

 Description   

Note: The most of the stack trace closely resembles MDEV-16694, but given the top frames (in create_tmp_table and a very different test case, I'm not sure at all it's the same issue, so filing it separately. See also MDEV-22600 for a variety of test cases very similar to this one, with different failures.

CREATE TABLE t1 (a INT);
CREATE TABLE t2 (d DATE NOT NULL, g GEOMETRY);
INSERT INTO t2 VALUES ('1981-09-12',NULL);
 
SET SQL_MODE= 'SIMULTANEOUS_ASSIGNMENT,STRICT_ALL_TABLES';
 
--error ER_BAD_NULL_ERROR
UPDATE t2 SET d = NULL, g = 42;
UPDATE t1 JOIN t2 SET d = NULL;
 
# Cleanup
DROP TABLE t1, t2;

10.3 ASAN 7476e8c7

==10765==ERROR: AddressSanitizer: use-after-poison on address 0x619000095761 at pc 0x7f146348ff7f bp 0x7f14573be650 sp 0x7f14573bde00
READ of size 3 at 0x619000095761 thread T5
    #0 0x7f146348ff7e  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x5cf7e)
    #1 0x55857c5dc1b7 in create_tmp_table(THD*, TMP_TABLE_PARAM*, List<Item>&, st_order*, bool, bool, unsigned long long, unsigned long long, st_mysql_const_lex_string const*, bool, bool) /data/src/10.3/sql/sql_select.cc:17960
    #2 0x55857c746c9c in multi_update::initialize_tables(JOIN*) /data/src/10.3/sql/sql_update.cc:2237
    #3 0x55857c56d8e4 in JOIN::optimize_stage2() /data/src/10.3/sql/sql_select.cc:2013
    #4 0x55857c56d27c in JOIN::optimize_inner() /data/src/10.3/sql/sql_select.cc:1968
    #5 0x55857c568ad1 in JOIN::optimize() /data/src/10.3/sql/sql_select.cc:1488
    #6 0x55857c58374e in mysql_select(THD*, TABLE_LIST*, unsigned int, List<Item>&, Item*, unsigned int, st_order*, st_order*, Item*, st_order*, unsigned long long, select_result*, st_select_lex_unit*, st_select_lex*) /data/src/10.3/sql/sql_select.cc:4292
    #7 0x55857c742c47 in mysql_multi_update(THD*, TABLE_LIST*, List<Item>*, List<Item>*, Item*, unsigned long long, enum_duplicates, bool, st_select_lex_unit*, st_select_lex*, multi_update**) /data/src/10.3/sql/sql_update.cc:1799
    #8 0x55857c4d192d in mysql_execute_command(THD*) /data/src/10.3/sql/sql_parse.cc:4369
    #9 0x55857c4e86dc in mysql_parse(THD*, char*, unsigned int, Parser_state*, bool, bool) /data/src/10.3/sql/sql_parse.cc:7818
    #10 0x55857c4c309d in dispatch_command(enum_server_command, THD*, char*, unsigned int, bool, bool) /data/src/10.3/sql/sql_parse.cc:1856
    #11 0x55857c4bff49 in do_command(THD*) /data/src/10.3/sql/sql_parse.cc:1401
    #12 0x55857c836e33 in do_handle_one_connection(CONNECT*) /data/src/10.3/sql/sql_connect.cc:1403
    #13 0x55857c8367fa in handle_one_connection /data/src/10.3/sql/sql_connect.cc:1308
    #14 0x55857dcab12b in pfs_spawn_thread /data/src/10.3/storage/perfschema/pfs.cc:1869
    #15 0x7f146321d4a3 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x74a3)
    #16 0x7f1461351d0e in __clone (/lib/x86_64-linux-gnu/libc.so.6+0xe8d0e)
 
0x619000095761 is located 225 bytes inside of 1100-byte region [0x619000095680,0x619000095acc)
allocated by thread T5 here:
    #0 0x7f14634f4d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55857dddb548 in sf_malloc /data/src/10.3/mysys/safemalloc.c:118
    #2 0x55857ddad117 in my_malloc /data/src/10.3/mysys/my_malloc.c:101
    #3 0x55857dd8d63a in alloc_root /data/src/10.3/mysys/my_alloc.c:250
    #4 0x55857dd8ecbb in memdup_root /data/src/10.3/mysys/my_alloc.c:492
    #5 0x55857c7693e2 in TABLE_SHARE::init_from_binary_frm_image(THD*, bool, unsigned char const*, unsigned long) /data/src/10.3/sql/table.cc:1296
    #6 0x55857c764752 in open_table_def(THD*, TABLE_SHARE*, unsigned int) /data/src/10.3/sql/table.cc:680
    #7 0x55857c9ed320 in tdc_acquire_share(THD*, TABLE_LIST*, unsigned int, TABLE**) /data/src/10.3/sql/table_cache.cc:840
    #8 0x55857c372edc in open_table(THD*, TABLE_LIST*, Open_table_context*) /data/src/10.3/sql/sql_base.cc:1839
    #9 0x55857c37bef3 in open_and_process_table /data/src/10.3/sql/sql_base.cc:3718
    #10 0x55857c37e17e in open_tables(THD*, DDL_options_st const&, TABLE_LIST**, unsigned int*, unsigned int, Prelocking_strategy*) /data/src/10.3/sql/sql_base.cc:4187
    #11 0x55857c38309b in open_and_lock_tables(THD*, DDL_options_st const&, TABLE_LIST*, bool, unsigned int, Prelocking_strategy*) /data/src/10.3/sql/sql_base.cc:5084
    #12 0x55857c2f4999 in open_and_lock_tables(THD*, TABLE_LIST*, bool, unsigned int) /data/src/10.3/sql/sql_base.h:505
    #13 0x55857c434cf2 in mysql_insert(THD*, TABLE_LIST*, List<Item>&, List<List<Item> >&, List<Item>&, List<Item>&, enum_duplicates, bool) /data/src/10.3/sql/sql_insert.cc:760
    #14 0x55857c4d1f69 in mysql_execute_command(THD*) /data/src/10.3/sql/sql_parse.cc:4454
    #15 0x55857c4e86dc in mysql_parse(THD*, char*, unsigned int, Parser_state*, bool, bool) /data/src/10.3/sql/sql_parse.cc:7818
    #16 0x55857c4c309d in dispatch_command(enum_server_command, THD*, char*, unsigned int, bool, bool) /data/src/10.3/sql/sql_parse.cc:1856
    #17 0x55857c4bff49 in do_command(THD*) /data/src/10.3/sql/sql_parse.cc:1401
    #18 0x55857c836e33 in do_handle_one_connection(CONNECT*) /data/src/10.3/sql/sql_connect.cc:1403
    #19 0x55857c8367fa in handle_one_connection /data/src/10.3/sql/sql_connect.cc:1308
    #20 0x55857dcab12b in pfs_spawn_thread /data/src/10.3/storage/perfschema/pfs.cc:1869
    #21 0x7f146321d4a3 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x74a3)
 
Thread T5 created by T0 here:
    #0 0x7f1463463f59 in __interceptor_pthread_create (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x30f59)
    #1 0x55857dcab567 in spawn_thread_v1 /data/src/10.3/storage/perfschema/pfs.cc:1919
    #2 0x55857c22c480 in inline_mysql_thread_create /data/src/10.3/include/mysql/psi/mysql_thread.h:1275
    #3 0x55857c24196f in create_thread_to_handle_connection(CONNECT*) /data/src/10.3/sql/mysqld.cc:6606
    #4 0x55857c242052 in create_new_thread /data/src/10.3/sql/mysqld.cc:6676
    #5 0x55857c24306a in handle_connections_sockets() /data/src/10.3/sql/mysqld.cc:6951
    #6 0x55857c240e3f in mysqld_main(int, char**) /data/src/10.3/sql/mysqld.cc:6228
    #7 0x55857c22ab9f in main /data/src/10.3/sql/main.cc:25
    #8 0x7f14612892e0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202e0)
 
SUMMARY: AddressSanitizer: use-after-poison (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x5cf7e) 
Shadow bytes around the buggy address:
  0x0c328000aa90: 00 f7 00 00 00 04 f7 00 00 f7 f7 f7 f7 f7 f7 f7
  0x0c328000aaa0: f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7
  0x0c328000aab0: f7 f7 f7 f7 f7 f7 f7 f7 f7 04 fa fa fa fa fa fa
  0x0c328000aac0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c328000aad0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c328000aae0: 00 f7 00 00 f7 01 f7 02 f7 00 00 f7[f7]01 f7 00
  0x0c328000aaf0: 00 00 00 00 00 00 00 00 00 00 00 00 f7 00 00 00
  0x0c328000ab00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c328000ab10: 00 00 00 00 00 00 00 f7 00 00 00 00 00 00 00 00
  0x0c328000ab20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c328000ab30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f7
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10765==ABORTING

10.5 03dcdad2 ASAN

==10975==ERROR: AddressSanitizer: use-after-poison on address 0x619000097a79 at pc 0x7fa08a868f7f bp 0x7fa07fdb1e90 sp 0x7fa07fdb1640
READ of size 3 at 0x619000097a79 thread T5
    #0 0x7fa08a868f7e  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x5cf7e)
    #1 0x55c1b55111c5 in Create_tmp_table::finalize(THD*, TABLE*, TMP_TABLE_PARAM*, bool, bool) /data/src/10.5/sql/sql_select.cc:18799
    #2 0x55c1b5516602 in create_tmp_table(THD*, TMP_TABLE_PARAM*, List<Item>&, st_order*, bool, bool, unsigned long long, unsigned long long, st_mysql_const_lex_string const*, bool, bool) /data/src/10.5/sql/sql_select.cc:19172
    #3 0x55c1b56a0e0e in multi_update::initialize_tables(JOIN*) /data/src/10.5/sql/sql_update.cc:2362
    #4 0x55c1b549ceb7 in JOIN::optimize_stage2() /data/src/10.5/sql/sql_select.cc:2334
    #5 0x55c1b549c6d1 in JOIN::optimize_inner() /data/src/10.5/sql/sql_select.cc:2286
    #6 0x55c1b5495f04 in JOIN::optimize() /data/src/10.5/sql/sql_select.cc:1606
    #7 0x55c1b54b3ba1 in mysql_select(THD*, TABLE_LIST*, List<Item>&, Item*, unsigned int, st_order*, st_order*, Item*, st_order*, unsigned long long, select_result*, st_select_lex_unit*, st_select_lex*) /data/src/10.5/sql/sql_select.cc:4655
    #8 0x55c1b569ce64 in mysql_multi_update(THD*, TABLE_LIST*, List<Item>*, List<Item>*, Item*, unsigned long long, enum_duplicates, bool, st_select_lex_unit*, st_select_lex*, multi_update**) /data/src/10.5/sql/sql_update.cc:1929
    #9 0x55c1b53fddd2 in mysql_execute_command(THD*) /data/src/10.5/sql/sql_parse.cc:4477
    #10 0x55c1b5414267 in mysql_parse(THD*, char*, unsigned int, Parser_state*, bool, bool) /data/src/10.5/sql/sql_parse.cc:7991
    #11 0x55c1b53eebdc in dispatch_command(enum_server_command, THD*, char*, unsigned int, bool, bool) /data/src/10.5/sql/sql_parse.cc:1875
    #12 0x55c1b53eba5f in do_command(THD*) /data/src/10.5/sql/sql_parse.cc:1356
    #13 0x55c1b57a39a4 in do_handle_one_connection(CONNECT*, bool) /data/src/10.5/sql/sql_connect.cc:1411
    #14 0x55c1b57a3413 in handle_one_connection /data/src/10.5/sql/sql_connect.cc:1313
    #15 0x55c1b63878cc in pfs_spawn_thread /data/src/10.5/storage/perfschema/pfs.cc:2201
    #16 0x7fa08a5f64a3 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x74a3)
    #17 0x7fa08872ad0e in __clone (/lib/x86_64-linux-gnu/libc.so.6+0xe8d0e)
 
0x619000097a79 is located 249 bytes inside of 1124-byte region [0x619000097980,0x619000097de4)
allocated by thread T5 here:
    #0 0x7fa08a8cdd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c1b6e97d84 in sf_malloc /data/src/10.5/mysys/safemalloc.c:118
    #2 0x55c1b6e68f34 in my_malloc /data/src/10.5/mysys/my_malloc.c:88
    #3 0x55c1b6e49293 in alloc_root /data/src/10.5/mysys/my_alloc.c:243
    #4 0x55c1b6e4a7c2 in memdup_root /data/src/10.5/mysys/my_alloc.c:478
    #5 0x55c1b56c5de8 in TABLE_SHARE::init_from_binary_frm_image(THD*, bool, unsigned char const*, unsigned long, unsigned char const*, unsigned long) /data/src/10.5/sql/table.cc:1773
    #6 0x55c1b56beab7 in open_table_def(THD*, TABLE_SHARE*, unsigned int) /data/src/10.5/sql/table.cc:704
    #7 0x55c1b596d4a3 in tdc_acquire_share(THD*, TABLE_LIST*, unsigned int, TABLE**) /data/src/10.5/sql/table_cache.cc:831
    #8 0x55c1b52804c3 in open_table(THD*, TABLE_LIST*, Open_table_context*) /data/src/10.5/sql/sql_base.cc:1836
    #9 0x55c1b5289737 in open_and_process_table /data/src/10.5/sql/sql_base.cc:3736
    #10 0x55c1b528bda5 in open_tables(THD*, DDL_options_st const&, TABLE_LIST**, unsigned int*, unsigned int, Prelocking_strategy*) /data/src/10.5/sql/sql_base.cc:4210
    #11 0x55c1b5290b10 in open_and_lock_tables(THD*, DDL_options_st const&, TABLE_LIST*, bool, unsigned int, Prelocking_strategy*) /data/src/10.5/sql/sql_base.cc:5112
    #12 0x55c1b51faeeb in open_and_lock_tables(THD*, TABLE_LIST*, bool, unsigned int) /data/src/10.5/sql/sql_base.h:509
    #13 0x55c1b534708c in mysql_insert(THD*, TABLE_LIST*, List<Item>&, List<List<Item> >&, List<Item>&, List<Item>&, enum_duplicates, bool, select_result*) /data/src/10.5/sql/sql_insert.cc:756
    #14 0x55c1b53fe591 in mysql_execute_command(THD*) /data/src/10.5/sql/sql_parse.cc:4553
    #15 0x55c1b5414267 in mysql_parse(THD*, char*, unsigned int, Parser_state*, bool, bool) /data/src/10.5/sql/sql_parse.cc:7991
    #16 0x55c1b53eebdc in dispatch_command(enum_server_command, THD*, char*, unsigned int, bool, bool) /data/src/10.5/sql/sql_parse.cc:1875
    #17 0x55c1b53eba5f in do_command(THD*) /data/src/10.5/sql/sql_parse.cc:1356
    #18 0x55c1b57a39a4 in do_handle_one_connection(CONNECT*, bool) /data/src/10.5/sql/sql_connect.cc:1411
    #19 0x55c1b57a3413 in handle_one_connection /data/src/10.5/sql/sql_connect.cc:1313
    #20 0x55c1b63878cc in pfs_spawn_thread /data/src/10.5/storage/perfschema/pfs.cc:2201
    #21 0x7fa08a5f64a3 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x74a3)
 
Thread T5 created by T0 here:
    #0 0x7fa08a83cf59 in __interceptor_pthread_create (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x30f59)
    #1 0x55c1b638298e in my_thread_create /data/src/10.5/storage/perfschema/my_thread.h:34
    #2 0x55c1b6387cbb in pfs_spawn_thread_v1 /data/src/10.5/storage/perfschema/pfs.cc:2252
    #3 0x55c1b5135637 in inline_mysql_thread_create /data/src/10.5/include/mysql/psi/mysql_thread.h:1321
    #4 0x55c1b5148369 in create_thread_to_handle_connection(CONNECT*) /data/src/10.5/sql/mysqld.cc:5952
    #5 0x55c1b51488de in create_new_thread(CONNECT*) /data/src/10.5/sql/mysqld.cc:6011
    #6 0x55c1b5148a9b in handle_accepted_socket(st_mysql_socket, st_mysql_socket) /data/src/10.5/sql/mysqld.cc:6076
    #7 0x55c1b514947e in handle_connections_sockets() /data/src/10.5/sql/mysqld.cc:6203
    #8 0x55c1b5147ccf in mysqld_main(int, char**) /data/src/10.5/sql/mysqld.cc:5621
    #9 0x55c1b5133e2f in main /data/src/10.5/sql/main.cc:25
    #10 0x7fa0886622e0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202e0)
 
SUMMARY: AddressSanitizer: use-after-poison (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x5cf7e) 
Shadow bytes around the buggy address:
  0x0c328000aef0: 00 00 00 00 00 f7 00 00 00 04 f7 00 00 f7 f7 f7
  0x0c328000af00: f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7
  0x0c328000af10: f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 04 fa fa fa
  0x0c328000af20: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c328000af30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c328000af40: 00 00 00 00 f7 00 00 f7 01 f7 02 f7 00 00 f7[f7]
  0x0c328000af50: 01 f7 00 00 00 00 00 00 00 00 00 f7 00 00 00 00
  0x0c328000af60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c328000af70: 00 00 00 00 00 00 f7 00 00 00 00 00 00 00 00 00
  0x0c328000af80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c328000af90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f7
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10975==ABORTING

Both debug- and non-debug ASAN builds are affected.
No obvious problem on a non-ASAN build.
Reproducible on 10.3-10.5. The test case is not applicable to 10.2 due to SIMULTANEOUS_ASSIGNMENT.



 Comments   
Comment by Elena Stepanova [ 2022-11-18 ]

Also fails with a single-table update:

CREATE TABLE t1 (a INT);
CREATE TABLE t2 (d DATE NOT NULL, g GEOMETRY);
INSERT INTO t2 VALUES ('1981-09-12',NULL);
 
SET SQL_MODE= 'SIMULTANEOUS_ASSIGNMENT,STRICT_ALL_TABLES';
 
--error ER_BAD_NULL_ERROR
UPDATE t2 SET d = NULL, g = 42;
 
UPDATE t2 SET d = '2022-12-12';
 
# Cleanup
DROP TABLE t1, t2;

10.3 df4c3d96

==3981377==ERROR: AddressSanitizer: use-after-poison on address 0x6190000820e9 at pc 0x7f66f32b2f29 bp 0x7f66e7c3b490 sp 0x7f66e7c3ac40
READ of size 3 at 0x6190000820e9 thread T5
    #0 0x7f66f32b2f28 in MemcmpInterceptorCommon(void*, int (*)(void const*, void const*, unsigned long), void const*, void const*, unsigned long) ../../../../src/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:840
    #1 0x7f66f32b3648 in __interceptor_memcmp ../../../../src/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:871
    #2 0x7f66f32b3648 in __interceptor_memcmp ../../../../src/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:866
    #3 0x55efb26e27c7 in Field::cmp_binary(unsigned char const*, unsigned char const*, unsigned int) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/field.h:1101
    #4 0x55efb26e291d in Field::cmp_binary_offset(unsigned int) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/field.h:1105
    #5 0x55efb22581ca in compare_record(TABLE const*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_update.cc:120
    #6 0x55efb225e98b in mysql_update(THD*, TABLE_LIST*, List<Item>&, List<Item>&, Item*, unsigned int, st_order*, unsigned long long, bool, unsigned long long*, unsigned long long*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_update.cc:911
    #7 0x55efb1fbbac9 in mysql_execute_command(THD*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:4344
    #8 0x55efb1fd4675 in mysql_parse(THD*, char*, unsigned int, Parser_state*, bool, bool) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:7855
    #9 0x55efb1fabcc3 in dispatch_command(enum_server_command, THD*, char*, unsigned int, bool, bool) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:1852
    #10 0x55efb1fa887b in do_command(THD*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:1398
    #11 0x55efb236c235 in do_handle_one_connection(CONNECT*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_connect.cc:1403
    #12 0x55efb236bb31 in handle_one_connection /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_connect.cc:1308
    #13 0x55efb391888c in pfs_spawn_thread /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/storage/perfschema/pfs.cc:1869
    #14 0x7f66f29cbea6 in start_thread nptl/pthread_create.c:477
    #15 0x7f66f28ebaee in __clone (/lib/x86_64-linux-gnu/libc.so.6+0xfcaee)
 
0x6190000820e9 is located 105 bytes inside of 992-byte region [0x619000082080,0x619000082460)
allocated by thread T5 here:
    #0 0x7f66f32d1e8f in __interceptor_malloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:145
    #1 0x55efb3a2cba8 in my_malloc /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/mysys/my_malloc.c:101
    #2 0x55efb3a09967 in alloc_root /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/mysys/my_alloc.c:251
    #3 0x55efb3a0b098 in strmake_root /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/mysys/my_alloc.c:481
    #4 0x55efb22a1932 in open_table_from_share(THD*, TABLE_SHARE*, st_mysql_const_lex_string const*, unsigned int, unsigned int, unsigned int, TABLE*, bool, List<String>*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/table.cc:3339
    #5 0x55efb1e45bbb in open_table(THD*, TABLE_LIST*, Open_table_context*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_base.cc:2005
    #6 0x55efb1e4ea19 in open_and_process_table /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_base.cc:3733
    #7 0x55efb1e5105d in open_tables(THD*, DDL_options_st const&, TABLE_LIST**, unsigned int*, unsigned int, Prelocking_strategy*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_base.cc:4208
    #8 0x55efb1e56014 in open_and_lock_tables(THD*, DDL_options_st const&, TABLE_LIST*, bool, unsigned int, Prelocking_strategy*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_base.cc:5148
    #9 0x55efb1dbd142 in open_and_lock_tables(THD*, TABLE_LIST*, bool, unsigned int) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_base.h:503
    #10 0x55efb1f153d8 in mysql_insert(THD*, TABLE_LIST*, List<Item>&, List<List<Item> >&, List<Item>&, List<Item>&, enum_duplicates, bool) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_insert.cc:760
    #11 0x55efb1fbc9d2 in mysql_execute_command(THD*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:4505
    #12 0x55efb1fd4675 in mysql_parse(THD*, char*, unsigned int, Parser_state*, bool, bool) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:7855
    #13 0x55efb1fabcc3 in dispatch_command(enum_server_command, THD*, char*, unsigned int, bool, bool) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:1852
    #14 0x55efb1fa887b in do_command(THD*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_parse.cc:1398
    #15 0x55efb236c235 in do_handle_one_connection(CONNECT*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_connect.cc:1403
    #16 0x55efb236bb31 in handle_one_connection /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/sql_connect.cc:1308
    #17 0x55efb391888c in pfs_spawn_thread /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/storage/perfschema/pfs.cc:1869
    #18 0x7f66f29cbea6 in start_thread nptl/pthread_create.c:477
 
Thread T5 created by T0 here:
    #0 0x7f66f327d2a2 in __interceptor_pthread_create ../../../../src/libsanitizer/asan/asan_interceptors.cpp:214
    #1 0x55efb3918c79 in spawn_thread_v1 /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/storage/perfschema/pfs.cc:1919
    #2 0x55efb1ce0d96 in inline_mysql_thread_create /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/include/mysql/psi/mysql_thread.h:1275
    #3 0x55efb1cf8f73 in create_thread_to_handle_connection(CONNECT*) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/mysqld.cc:6677
    #4 0x55efb1cf96d3 in create_new_thread /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/mysqld.cc:6747
    #5 0x55efb1cfa83d in handle_connections_sockets() /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/mysqld.cc:7005
    #6 0x55efb1cf82f3 in mysqld_main(int, char**) /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/mysqld.cc:6299
    #7 0x55efb1cdf624 in main /home/jenkins/workspace/sandbox-elenst/Nightly-Build-CS/src/sql/main.cc:25
    #8 0x7f66f2812d09 in __libc_start_main ../csu/libc-start.c:308
 
SUMMARY: AddressSanitizer: use-after-poison ../../../../src/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:840 in MemcmpInterceptorCommon(void*, int (*)(void const*, void const*, unsigned long), void const*, void const*, unsigned long)
Shadow bytes around the buggy address:
  0x0c32800083c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c32800083d0: 00 00 f7 04 f7 04 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7
  0x0c32800083e0: f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 f7 fa fa fa fa
  0x0c32800083f0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3280008400: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
=>0x0c3280008410: 00 00 00 00 f7 03 f7 00 00 f7 00 00 f7[f7]00 00
  0x0c3280008420: 00 f7 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3280008430: 00 00 00 00 00 00 00 00 00 00 00 00 f7 00 00 00
  0x0c3280008440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3280008450: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3280008460: 00 00 00 00 f7 00 00 00 04 f7 00 00 f7 f7 f7 f7
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
  Shadow gap:              cc
==3981377==ABORTING

Generated at Thu Feb 08 09:17:02 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.