[MDEV-21692] UBSAN error: load of value 2779096485, which is not a valid value for type enum_binlog_format Created: 2020-02-09  Updated: 2020-03-23  Resolved: 2020-03-23

Status: Closed
Project: MariaDB Server
Component/s: Replication
Affects Version/s: 10.3, 10.5
Fix Version/s: 10.2.32, 10.3.23, 10.4.13, 10.5.2

Type: Bug Priority: Critical
Reporter: Sergei Petrunia Assignee: Sachin Setiya (Inactive)
Resolution: Duplicate Votes: 0
Labels: None

Issue Links:
Duplicate
duplicates MDEV-19658 UBSAN: runtime error: load of value 2... Closed
Relates
relates to MDEV-21341 Fix UBSAN failures Confirmed

 Description   

Compile with UBSan like it is described in MDEV-21341.

Run pretty much any test like so:

UBSAN_OPTIONS=print_stacktrace=1 ./mtr alias

and observe the error:

/home/psergey/dev-git2/10.5/sql/sql_class.h:4169:24: runtime error: load of value 2779096485, which is not a valid value for type 'enum_binlog_format'
    #0 0x56245d5aa9bd in THD::set_current_stmt_binlog_format_stmt() /home/psergey/dev-git2/10.5/sql/sql_class.h:4169
    #1 0x56245d6c5842 in THD::reset_current_stmt_binlog_format_row() /home/psergey/dev-git2/10.5/sql/sql_class.h:4208
    #2 0x56245d66142c in THD::init() /home/psergey/dev-git2/10.5/sql/sql_class.cc:1286
    #3 0x56245d65a27b in THD::THD(unsigned long long, bool) /home/psergey/dev-git2/10.5/sql/sql_class.cc:841
    #4 0x56245d8bc5c4 in plugin_load /home/psergey/dev-git2/10.5/sql/sql_plugin.cc:1813
    #5 0x56245d8bc14d in plugin_init(int*, char**, int) /home/psergey/dev-git2/10.5/sql/sql_plugin.cc:1746
    #6 0x56245d3d293a in init_server_components /home/psergey/dev-git2/10.5/sql/mysqld.cc:5008
    #7 0x56245d3d4350 in mysqld_main(int, char**) /home/psergey/dev-git2/10.5/sql/mysqld.cc:5536
    #8 0x56245d3c13b9 in main /home/psergey/dev-git2/10.5/sql/main.cc:25
    #9 0x7f50b7c72b96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
    #10 0x56245d3c12b9 in _start (/optane/dev-git2/10.5/sql/mysqld+0x32572b9)



 Comments   
Comment by Marko Mäkelä [ 2020-03-19 ]

This seems to be duplicating MDEV-19658.

Comment by Eugene Kosov (Inactive) [ 2020-03-23 ]

Original issue was fixed in https://github.com/MariaDB/server/commit/1e6be6938059d230903029fa99ad6504c53d90ea

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