Commit 3968a1b0 authored by Luis Soares's avatar Luis Soares

Post-push fix for BUG#50364.

There was an erroneous parameter when calling flush_master_info
from write_ignored_events_info_to_relay_log which could lead to a
server crash. This happens because the I/O thread releases the
log_lock before calling the flush_master_info.

Set the function to call flush_master_info with third parameter
to true, so that the mutex is properly taken.
parent de2ee07d
...@@ -1726,7 +1726,7 @@ static void write_ignored_events_info_to_relay_log(THD *thd, Master_info *mi) ...@@ -1726,7 +1726,7 @@ static void write_ignored_events_info_to_relay_log(THD *thd, Master_info *mi)
" to the relay log, SHOW SLAVE STATUS may be" " to the relay log, SHOW SLAVE STATUS may be"
" inaccurate"); " inaccurate");
rli->relay_log.harvest_bytes_written(&rli->log_space_total); rli->relay_log.harvest_bytes_written(&rli->log_space_total);
if (flush_master_info(mi, TRUE, FALSE)) if (flush_master_info(mi, TRUE, TRUE))
sql_print_error("Failed to flush master info file"); sql_print_error("Failed to flush master info file");
delete ev; delete ev;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment