Commit 46f96a30 authored by unknown's avatar unknown

Avoid segfault when LOAD DATA FROM MASTER is run on a master which does no

binary logging.


sql/repl_failsafe.cc:
  If the master is running without --log-bin, SHOW MASTER STATUS will return
  "empty set", i.e. row==0; we must test this before invoking row[0], or
  segfault.
parent 6ccebbaf
......@@ -860,7 +860,7 @@ int load_master_data(THD* thd)
of LOAD DATA FROM MASTER - no reason to forbid it, really,
although it does not make much sense for the user to do it
*/
if (row[0] && row[1])
if (row && row[0] && row[1])
{
strmake(active_mi->master_log_name, row[0],
sizeof(active_mi->master_log_name));
......
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