List:Commits« Previous MessageNext Message »
From:Frazer Clement Date:March 15 2011 11:14am
Subject:bzr commit into mysql-5.1-telco-6.3 branch (frazer:3400) Bug#11765707
Bug#11799583
View as plain text  
#At file:///home/frazer/bzr/mysql-5.1-telco-6.3/ based on revid:frazer@stripped

 3400 Frazer Clement	2011-03-15
      Reduce footprint of backport of bug#11799583 (bug#11765707)

    modified:
      sql/log.cc
      sql/log_event.h
=== modified file 'sql/log.cc'
--- a/sql/log.cc	2011-03-14 23:28:51 +0000
+++ b/sql/log.cc	2011-03-15 11:14:43 +0000
@@ -4324,10 +4324,7 @@ bool MYSQL_BIN_LOG::write(Log_event *eve
       binlog_[wild_]{do|ignore}_table?" (WL#1049)"
     */
     const char *local_db= event_info->get_db();
-    if (
-#ifndef MCP_BUG11799583
-        (event_info->flags & LOG_EVENT_NO_FILTER_F) == 0 &&
-#endif
+    if ((event_info->flags & LOG_EVENT_NO_DB_CHECK_F) == 0 &&
         ((thd && !(thd->options & OPTION_BIN_LOG)) ||
          (thd->lex->sql_command != SQLCOM_ROLLBACK_TO_SAVEPOINT &&
           thd->lex->sql_command != SQLCOM_SAVEPOINT &&

=== modified file 'sql/log_event.h'
--- a/sql/log_event.h	2011-03-14 22:52:14 +0000
+++ b/sql/log_event.h	2011-03-15 11:14:43 +0000
@@ -494,13 +494,19 @@ struct sql_ex_info
 */
 #define LOG_EVENT_RELAY_LOG_F 0x40
 
-#ifndef MCP_BUG11799583
 /**
    Events with this flag are not filtered based on the current
    database and is always written to the binary log regardless of
    filters.
  */
-#define LOG_EVENT_NO_FILTER_F 0x80
+#define LOG_EVENT_NO_DB_CHECK_F 0x80
+
+#ifndef MCP_BUG11799583
+/* 
+   Define LOG_EVENT_NO_FILTER_F as alias for LOG_EVENT_NO_DB_CHECK
+   to make it possible to write code that is forward compatible with 5.5
+*/
+#define LOG_EVENT_NO_FILTER_F LOG_EVENT_NO_DB_CHECK_F
 #endif
 
 /**
@@ -3930,13 +3936,7 @@ class Incident_log_event : public Log_ev
 public:
 #ifndef MYSQL_CLIENT
   Incident_log_event(THD *thd_arg, Incident incident)
-    : Log_event(thd_arg,
-#ifndef MCP_BUG11799583 
-                LOG_EVENT_NO_FILTER_F,
-#else
-                0,
-#endif
-                FALSE), m_incident(incident)
+    : Log_event(thd_arg, LOG_EVENT_NO_DB_CHECK_F, FALSE), m_incident(incident)
   {
     DBUG_ENTER("Incident_log_event::Incident_log_event");
     DBUG_PRINT("enter", ("m_incident: %d", m_incident));
@@ -3946,13 +3946,7 @@ public:
   }
 
   Incident_log_event(THD *thd_arg, Incident incident, LEX_STRING const msg)
-    : Log_event(thd_arg,
-#ifndef MCP_BUG11799583 
-                LOG_EVENT_NO_FILTER_F,
-#else
-                0,
-#endif
-                FALSE), m_incident(incident)
+    : Log_event(thd_arg, LOG_EVENT_NO_DB_CHECK_F, FALSE), m_incident(incident)
   {
     DBUG_ENTER("Incident_log_event::Incident_log_event");
     DBUG_PRINT("enter", ("m_incident: %d", m_incident));


Attachment: [text/bzr-bundle] bzr/frazer@mysql.com-20110315111443-c25v5unpn486fsqo.bundle
Thread
bzr commit into mysql-5.1-telco-6.3 branch (frazer:3400) Bug#11765707Bug#11799583Frazer Clement15 Mar