List:Commits« Previous MessageNext Message »
From:Georgi Kodinov Date:November 24 2009 10:43am
Subject:bzr commit into mysql-5.1-bugteam branch (joro:3219) Bug#48985
View as plain text  
#At file:///home/kgeorge/mysql/work/B48985-5.1-bugteam/ based on revid:jimw@stripped

 3219 Georgi Kodinov	2009-11-24
      Bug #48985: show create table crashes if previous access to the table was killed
      
      When checking for an error after removing the special view error handler the code
      was not taking into account that open_tables() may fail because of the current
      statement being killed. 
      Added a check for thd->killed.

    modified:
      sql/sql_show.cc
=== modified file 'sql/sql_show.cc'
--- a/sql/sql_show.cc	2009-10-16 10:29:42 +0000
+++ b/sql/sql_show.cc	2009-11-24 10:43:05 +0000
@@ -719,7 +719,7 @@ mysqld_show_create(THD *thd, TABLE_LIST 
     thd->push_internal_handler(&view_error_suppressor);
     bool error= open_normal_and_derived_tables(thd, table_list, 0);
     thd->pop_internal_handler();
-    if (error && thd->main_da.is_error())
+    if (error && (thd->killed || thd->main_da.is_error()))
       DBUG_RETURN(TRUE);
   }
 


Attachment: [text/bzr-bundle] bzr/joro@sun.com-20091124104305-cnyuwhsik3tm39dy.bundle
Thread
bzr commit into mysql-5.1-bugteam branch (joro:3219) Bug#48985Georgi Kodinov24 Nov