List:Commits« Previous MessageNext Message »
From:Li-Bing.Song Date:November 3 2009 10:50am
Subject:bzr commit into mysql-pe branch (Li-Bing.Song:3657)
View as plain text  
#At file:///home/anders/work/bzrwork/worktree1/mysql-pe/ based on revid:davi.arnaut@stripped

 3657 Li-Bing.Song@stripped	2009-11-03 [merge]
      Auto Merge

    modified:
      mysql-test/extra/binlog_tests/drop_temp_table.test
      mysql-test/suite/binlog/r/binlog_row_drop_tmp_tbl.result
      mysql-test/suite/binlog/r/binlog_stm_drop_tmp_tbl.result
      sql/sql_base.cc
=== modified file 'mysql-test/extra/binlog_tests/drop_temp_table.test'
--- a/mysql-test/extra/binlog_tests/drop_temp_table.test	2009-09-28 02:23:06 +0000
+++ b/mysql-test/extra/binlog_tests/drop_temp_table.test	2009-11-03 10:20:08 +0000
@@ -48,6 +48,16 @@ DROP TABLE IF EXISTS tmp2, t;
 --enable_warnings
 
 SELECT GET_LOCK("a",10);
+
+#
+# BUG48216 Replication fails on all slaves after upgrade to 5.0.86 on master
+#
+# When the session is closed, any temporary tables of the session are dropped
+# and are binlogged. But it will be binlogged with a wrong database name when
+# the length of the database name('drop-temp-table-test') is greater than the
+# current database name('test').
+#
+USE test;
 disconnect con1;
 
 connection con2;

=== modified file 'mysql-test/suite/binlog/r/binlog_row_drop_tmp_tbl.result'
--- a/mysql-test/suite/binlog/r/binlog_row_drop_tmp_tbl.result	2009-09-28 02:23:06 +0000
+++ b/mysql-test/suite/binlog/r/binlog_row_drop_tmp_tbl.result	2009-11-03 10:20:08 +0000
@@ -19,6 +19,7 @@ DROP TABLE IF EXISTS tmp2, t;
 SELECT GET_LOCK("a",10);
 GET_LOCK("a",10)
 1
+USE test;
 SELECT GET_LOCK("a",10);
 GET_LOCK("a",10)
 1

=== modified file 'mysql-test/suite/binlog/r/binlog_stm_drop_tmp_tbl.result'
--- a/mysql-test/suite/binlog/r/binlog_stm_drop_tmp_tbl.result	2009-09-28 02:23:06 +0000
+++ b/mysql-test/suite/binlog/r/binlog_stm_drop_tmp_tbl.result	2009-11-03 10:20:08 +0000
@@ -19,6 +19,7 @@ DROP TABLE IF EXISTS tmp2, t;
 SELECT GET_LOCK("a",10);
 GET_LOCK("a",10)
 1
+USE test;
 SELECT GET_LOCK("a",10);
 GET_LOCK("a",10)
 1

=== modified file 'sql/sql_base.cc'
--- a/sql/sql_base.cc	2009-11-03 09:42:49 +0000
+++ b/sql/sql_base.cc	2009-11-03 10:49:31 +0000
@@ -1683,6 +1683,7 @@ void close_temporary_tables(THD *thd)
                             s_query.length() - 1 /* to remove trailing ',' */,
                             0, FALSE, 0);
       qinfo.db= db.ptr();
+      qinfo.db_len= db.length();
       thd->variables.character_set_client= cs_save;
       mysql_bin_log.write(&qinfo);
       thd->variables.pseudo_thread_id= save_pseudo_thread_id;


Attachment: [text/bzr-bundle] bzr/li-bing.song@sun.com-20091103104931-uy8bb7jte6uwowof.bundle
Thread
bzr commit into mysql-pe branch (Li-Bing.Song:3657) Li-Bing.Song3 Nov