List:Commits« Previous MessageNext Message »
From:Dmitry Shulga Date:August 29 2011 6:54am
Subject:bzr push into mysql-trunk branch (Dmitry.Shulga:3408 to 3409) Bug#11749050
View as plain text  
 3409 Dmitry Shulga	2011-08-29
      Fixed bug#11749050 (formerly known as 38028): Assert hit in function
      open_table_def in file table.cc
      
      This bug relates only to the case when storage handlerton exposes
      the flag HTON_FLUSH_AFTER_RENAME and user issues ALTER statement
      that contains RENAME clause. In this case server, built in debug mode,
      has crashed on assert.
      
      The reason for this bug was that, when temporary table was opened before
      flushing storage engine log, the old name of table was used. Since at
      this point table with this name no longer existed assert was triggered.
      
      The solution is to open new (renamed version of table) table before
      flushing storage engine log.
      
      Testcase for this bug is missing because none of currently supported
      storage engines exposes the flag HTON_FLUSH_AFTER_RENAME.
     @ sql/sql_table.cc
        mysql_alter_table was modified: now we use correct table name when opening
        table before flushing SE log.

    modified:
      sql/sql_table.cc
 3408 Matthias Leich	2011-08-27
      Bug#12921422 - SOCKET_SUMMARY_BY_INSTANCE_FUNC_WIN FAILS IN PB
      This fix already passed PB on tree mysql-trunk-wl4896.

    modified:
      mysql-test/suite/perfschema/r/socket_summary_by_instance_func.result
      mysql-test/suite/perfschema/r/socket_summary_by_instance_func_win.result
      mysql-test/suite/perfschema/t/socket_summary_by_instance_func.test
      mysql-test/suite/perfschema/t/socket_summary_by_instance_func_win.test
=== modified file 'sql/sql_table.cc'
--- a/sql/sql_table.cc	2011-08-19 13:04:28 +0000
+++ b/sql/sql_table.cc	2011-08-29 06:53:25 +0000
@@ -7072,8 +7072,8 @@ bool mysql_alter_table(THD *thd,char *ne
     */
     char path[FN_REFLEN];
     TABLE *t_table;
-    build_table_filename(path + 1, sizeof(path) - 1, new_db, table_name, "", 0);
-    t_table= open_table_uncached(thd, path, new_db, tmp_name, FALSE);
+    build_table_filename(path, sizeof(path) - 1, new_db, new_name, "", 0);
+    t_table= open_table_uncached(thd, path, new_db, new_name, FALSE);
     if (t_table)
     {
       intern_close_table(t_table);

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-trunk branch (Dmitry.Shulga:3408 to 3409) Bug#11749050Dmitry Shulga29 Aug