summaryrefslogtreecommitdiff
path: root/sql/slave.cc
diff options
context:
space:
mode:
authorSeppo Jaakola <seppo.jaakola@codership.com>2012-08-09 01:47:21 +0300
committerSeppo Jaakola <seppo.jaakola@codership.com>2012-08-09 01:47:21 +0300
commitebfa24b1d24377a241b79883da96969a9150f22c (patch)
treeef1198f9dfb1838cbdbc5056f2b84e399b446bfd /sql/slave.cc
parent1fd2e10736d6fd198e62054cb9006a3dc13fd55e (diff)
parenta7123f507598690ef0fce68b5d8dc58e63635024 (diff)
downloadmariadb-git-ebfa24b1d24377a241b79883da96969a9150f22c.tar.gz
References lp:1034621 - Merge up to mysql-5.5.25 level
merged codership-mysql/5.5 revisions: bzr diff -r3759..3767 merged codership-mysql/5.5 revisions: bzr diff -r3768..3771
Diffstat (limited to 'sql/slave.cc')
-rw-r--r--sql/slave.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/sql/slave.cc b/sql/slave.cc
index 94a485cbe29..2b387012f85 100644
--- a/sql/slave.cc
+++ b/sql/slave.cc
@@ -2797,7 +2797,8 @@ static int exec_relay_log_event(THD* thd, Relay_log_info* rli)
/* fall through */
default:
DBUG_PRINT("info", ("Deleting the event after it has been executed"));
- delete ev;
+ if (!rli->is_deferred_event(ev))
+ delete ev;
break;
}
@@ -3461,6 +3462,12 @@ pthread_handler_t handle_slave_sql(void *arg)
goto err_during_init;
}
thd->init_for_queries();
+ thd->rli_slave= rli;
+ if ((rli->deferred_events_collecting= rpl_filter->is_on()))
+ {
+ rli->deferred_events= new Deferred_log_events(rli);
+ }
+
thd->temporary_tables = rli->save_temporary_tables; // restore temp tables
set_thd_in_use_temporary_tables(rli); // (re)set sql_thd in use for saved temp tables
/*