mirror of
https://github.com/MariaDB/server.git
synced 2026-05-16 20:07:13 +02:00
MDEV-18902 Uninitialized variable in recv_parse_log_recs()
recv_parse_log_recs(): Do not compare type if ptr==end_ptr (we have reached the end of the redo log parsing buffer), because it will not have been correctly initialized in that case.
This commit is contained in:
parent
e070cfe398
commit
bef947b4c9
1 changed files with 9 additions and 5 deletions
|
|
@ -2697,16 +2697,20 @@ loop:
|
|||
&type, ptr, end_ptr, &space, &page_no,
|
||||
false, &body);
|
||||
|
||||
if (recv_sys->found_corrupt_log
|
||||
|| type == MLOG_CHECKPOINT
|
||||
|| (ptr != end_ptr
|
||||
&& (*ptr & MLOG_SINGLE_REC_FLAG))) {
|
||||
recv_sys->found_corrupt_log = true;
|
||||
if (recv_sys->found_corrupt_log) {
|
||||
corrupted_log:
|
||||
recv_report_corrupt_log(
|
||||
ptr, type, space, page_no);
|
||||
return(true);
|
||||
}
|
||||
|
||||
if (ptr == end_ptr) {
|
||||
} else if (type == MLOG_CHECKPOINT
|
||||
|| (*ptr & MLOG_SINGLE_REC_FLAG)) {
|
||||
recv_sys->found_corrupt_log = true;
|
||||
goto corrupted_log;
|
||||
}
|
||||
|
||||
if (recv_sys->found_corrupt_fs) {
|
||||
return(true);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue