Hi Nirbhay, On Fri, Sep 02, 2016 at 09:00:27AM -0400, Nirbhay Choubey wrote: > > > diff --git a/sql/log_event.cc b/sql/log_event.cc > > > index afa58af..66e7c60 100644 > > > --- a/sql/log_event.cc > > > +++ b/sql/log_event.cc > > > @@ -6022,7 +6022,7 @@ int Load_log_event::do_apply_event(NET* net, > > rpl_group_info *rgi, > > > new_db.str= (char *) rpl_filter->get_rewrite_db(db, &new_db.length); > > > thd->set_db(new_db.str, new_db.length); > > > DBUG_ASSERT(thd->query() == 0); > > > - thd->reset_query_inner(); // Should not be needed > > > + if (thd->query()) thd->reset_query(); // Should not be needed > > Why if? Original code didn't have it. > > > > Now that we call reset_query(), the check has been added to avoid it and an > extra mutex. > And from the above assert, I think it will be ever better have this check > within unlikely(). Taking into account this assert I'd say there's no point in reset_query at all.
Regards, Sergey _______________________________________________ Mailing list: https://launchpad.net/~maria-developers Post to : maria-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-developers More help : https://help.launchpad.net/ListHelp