Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.11.19
-
Can result in hang or crash
Description
--source include/have_debug.inc
|
--source include/have_binlog_format_mixed.inc # format-agnostic
|
|
|
--let $MYSQL_DATADIR= `SELECT @@datadir`
|
--let $binlog_file= query_get_value(SHOW BINLOG STATUS, File, 1)
|
--let $binlog_start= query_get_value(SHOW BINLOG STATUS, Position, 1)
|
|
|
--exec $MYSQL_BINLOG --verify-binlog-checksum --force-read --debug=d,simulate_checksum_test_failure --start-position=$binlog_start $MYSQL_DATADIR/$binlog_file |
/path/to/src/client/mysqlbinlog.cc: runtime error: downcast of address which does not point to an object of type 'Format_description_log_event'
|
note: object is of type 'Unknown_log_event'
|
Code Analysis
In static check_header(), --start-position's prelude code that finds the Format Description uses C-cast (roughly equivalent to C++ reinterpret_cast()), which expects the event to be either a Format Description or nullptr.
But --force-read generates an Unknown event instead of a nullptr.
Fix Suggestions
- Use C++ dynamic_cast()
- Get rid of the entire check_header() prelude during MDEV-40760
Attachments
Issue Links
- is part of
-
MDEV-40760 Lift the runtime dependency on the current Format Description event
-
- Open
-
- split from
-
MDEV-40674
Include the checksum for non-corrupted Unknown events
-
- Closed
-