Below is the list of changes that have just been committed into a local
5.1 repository of istruewing. When istruewing does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2007-11-18 20:28:37+01:00, istruewing@stripped +3 -0
Bug#26379 - Combination of FLUSH TABLE and REPAIR TABLE
corrupts a MERGE table
Post-pushbuild fix for a Valgrind warning.
mysql-test/r/merge.result@stripped, 2007-11-18 20:28:35+01:00, istruewing@stripped +0 -4
Bug#26379 - Combination of FLUSH TABLE and REPAIR TABLE
corrupts a MERGE table
Fixed test result.
mysql-test/t/merge.test@stripped, 2007-11-18 20:28:35+01:00, istruewing@stripped +0 -2
Bug#26379 - Combination of FLUSH TABLE and REPAIR TABLE
corrupts a MERGE table
Removed unnecessary statements from test.
sql/sql_trigger.cc@stripped, 2007-11-18 20:28:35+01:00, istruewing@stripped +5 -2
Bug#26379 - Combination of FLUSH TABLE and REPAIR TABLE
corrupts a MERGE table
Fixed usage of db and table_name for
close_data_files_and_morph_locks().
diff -Nrup a/mysql-test/r/merge.result b/mysql-test/r/merge.result
--- a/mysql-test/r/merge.result 2007-11-15 20:25:40 +01:00
+++ b/mysql-test/r/merge.result 2007-11-18 20:28:35 +01:00
@@ -1875,10 +1875,6 @@ CHECK TABLE t1 EXTENDED;
Table Op Msg_type Msg_text
test.t1 check status OK
LOCK TABLES t2 WRITE, t1 WRITE;
-SELECT * FROM t2;
-c1
-1
-LOCK TABLES t2 WRITE, t1 WRITE;
REPAIR TABLE t1;
Table Op Msg_type Msg_text
test.t1 repair status OK
diff -Nrup a/mysql-test/t/merge.test b/mysql-test/t/merge.test
--- a/mysql-test/t/merge.test 2007-11-15 20:25:40 +01:00
+++ b/mysql-test/t/merge.test 2007-11-18 20:28:35 +01:00
@@ -1279,8 +1279,6 @@ CHECK TABLE t1 EXTENDED;
#
# Not using FLUSH TABLES before REPAIR.
LOCK TABLES t2 WRITE, t1 WRITE;
-SELECT * FROM t2;
-LOCK TABLES t2 WRITE, t1 WRITE;
REPAIR TABLE t1;
CHECK TABLE t1;
REPAIR TABLE t1;
diff -Nrup a/sql/sql_trigger.cc b/sql/sql_trigger.cc
--- a/sql/sql_trigger.cc 2007-11-15 20:25:41 +01:00
+++ b/sql/sql_trigger.cc 2007-11-18 20:28:35 +01:00
@@ -489,8 +489,11 @@ bool mysql_create_or_drop_trigger(THD *t
/* Under LOCK TABLES we must reopen the table to activate the trigger. */
if (!result && thd->locked_tables)
{
- close_data_files_and_morph_locks(thd, table->s->db.str,
- table->s->table_name.str);
+ /*
+ Must not use table->s->db.str or table->s->table_name.str here.
+ The strings are used in a loop even after the share may be freed.
+ */
+ close_data_files_and_morph_locks(thd, tables->db, tables->table_name);
thd->in_lock_tables= 1;
result= reopen_tables(thd, 1, 0);
thd->in_lock_tables= 0;