diff options
author | He Zhenxing <zhenxing.he@sun.com> | 2010-01-24 15:03:23 +0800 |
---|---|---|
committer | He Zhenxing <zhenxing.he@sun.com> | 2010-01-24 15:03:23 +0800 |
commit | 2b16517522afad76bc94b07bdaa8af64091e713b (patch) | |
tree | 30ea0d6bf62fef90f4f1499d15e388cb43241707 /sql/sql_repl.cc | |
parent | 16471fecc7084f2eb56c459ff209bf2491ff327d (diff) | |
download | mariadb-git-2b16517522afad76bc94b07bdaa8af64091e713b.tar.gz |
Backport Bug#37148 to 5.1
Diffstat (limited to 'sql/sql_repl.cc')
-rw-r--r-- | sql/sql_repl.cc | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/sql/sql_repl.cc b/sql/sql_repl.cc index de038f8dc2c..4b10d284611 100644 --- a/sql/sql_repl.cc +++ b/sql/sql_repl.cc @@ -1004,8 +1004,8 @@ int reset_slave(THD *thd, Master_info* mi) MY_STAT stat_area; char fname[FN_REFLEN]; int thread_mask= 0, error= 0; - uint sql_errno=0; - const char* errmsg=0; + uint sql_errno=ER_UNKNOWN_ERROR; + const char* errmsg= "Unknown error occured while reseting slave"; DBUG_ENTER("reset_slave"); lock_slave_threads(mi); @@ -1671,7 +1671,8 @@ err: replication events along LOAD DATA processing. @param file pointer to io-cache - @return 0 + @retval 0 success + @retval 1 failure */ int log_loaded_block(IO_CACHE* file) { @@ -1698,7 +1699,8 @@ int log_loaded_block(IO_CACHE* file) Append_block_log_event a(lf_info->thd, lf_info->thd->db, buffer, min(block_len, max_event_size), lf_info->log_delayed); - mysql_bin_log.write(&a); + if (mysql_bin_log.write(&a)) + DBUG_RETURN(1); } else { @@ -1706,7 +1708,8 @@ int log_loaded_block(IO_CACHE* file) buffer, min(block_len, max_event_size), lf_info->log_delayed); - mysql_bin_log.write(&b); + if (mysql_bin_log.write(&b)) + DBUG_RETURN(1); lf_info->wrote_create_file= 1; DBUG_SYNC_POINT("debug_lock.created_file_event",10); } |