MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:kroki Date:June 23 2006 9:25am
Subject:bk commit into 5.0 tree (kroki:1.2192) BUG#16581
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of tomash. When tomash 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
  1.2192 06/06/23 13:25:19 kroki@stripped +3 -0
  Bug#16581: deadlock: server and client both read from connection in
             'conc_sys' test
  
  There was a race between DROP TABLE and query to INFORMATION_SCHEMA.
  
  Since I_S is designed not to use locks, but to perhaps return partial data,
  we ignore all table open errors.

  sql/sql_show.cc
    1.320 06/06/23 13:25:10 kroki@stripped +12 -9
    If we can't open a table in a database in get_all_tables(), push a warning
    and continue operation.
    Make get_schema_tables_result() void function, as it never fails now.  On
    internal error push a warning and continue.

  sql/sql_select.cc
    1.423 06/06/23 13:25:10 kroki@stripped +4 -8
    get_schema_tables_result() never fails now.

  sql/mysql_priv.h
    1.394 06/06/23 13:25:09 kroki@stripped +1 -1
    Make get_schema_tables_result() void function.

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	kroki
# Host:	moonlight.intranet
# Root:	/home/tomash/src/mysql_ab/mysql-5.0-bug16581

--- 1.393/sql/mysql_priv.h	2006-05-26 12:51:14 +04:00
+++ 1.394/sql/mysql_priv.h	2006-06-23 13:25:09 +04:00
@@ -872,7 +872,7 @@
 int fill_schema_schema_privileges(THD *thd, TABLE_LIST *tables, COND *cond);
 int fill_schema_table_privileges(THD *thd, TABLE_LIST *tables, COND *cond);
 int fill_schema_column_privileges(THD *thd, TABLE_LIST *tables, COND *cond);
-bool get_schema_tables_result(JOIN *join);
+void get_schema_tables_result(JOIN *join);
 #define is_schema_db(X) \
   !my_strcasecmp(system_charset_info, information_schema_name.str, (X))
 

--- 1.422/sql/sql_select.cc	2006-06-03 03:55:50 +04:00
+++ 1.423/sql/sql_select.cc	2006-06-23 13:25:10 +04:00
@@ -1332,11 +1332,8 @@
   List<Item> *curr_fields_list= &fields_list;
   TABLE *curr_tmp_table= 0;
 
-  if ((curr_join->select_lex->options & OPTION_SCHEMA_TABLE) &&
-      get_schema_tables_result(curr_join))
-  {
-    DBUG_VOID_RETURN;
-  }
+  if (curr_join->select_lex->options & OPTION_SCHEMA_TABLE)
+    get_schema_tables_result(curr_join);
 
   /* Create a tmp table if distinct or if the sort is too complicated */
   if (need_tmp)
@@ -11534,9 +11531,8 @@
   }
 
   /* Fill schema tables with data before filesort if it's necessary */
-  if ((join->select_lex->options & OPTION_SCHEMA_TABLE) &&
-      get_schema_tables_result(join))
-    goto err;
+  if (join->select_lex->options & OPTION_SCHEMA_TABLE)
+    get_schema_tables_result(join);
 
   if (table->s->tmp_table)
     table->file->info(HA_STATUS_VARIABLE);	// Get record count

--- 1.319/sql/sql_show.cc	2006-06-06 10:25:25 +04:00
+++ 1.320/sql/sql_show.cc	2006-06-23 13:25:10 +04:00
@@ -2180,7 +2180,12 @@
         len= FN_LEN - len;
         if (mysql_find_files(thd, &files, base_name, 
                              path, idx_field_vals.table_value, 0))
-          goto err;
+        {
+          push_warning(thd, MYSQL_ERROR::WARN_LEVEL_WARN,
+                       thd->net.last_errno, thd->net.last_error);
+          thd->clear_error();
+          continue;
+        }
         if (lower_case_table_names)
           orig_base_name= thd->strdup(base_name);
       }
@@ -3885,18 +3890,13 @@
   SYNOPSIS
     get_schema_tables_result()
     join  join which use schema tables
-
-  RETURN
-    FALSE success
-    TRUE  error
 */
 
-bool get_schema_tables_result(JOIN *join)
+void get_schema_tables_result(JOIN *join)
 {
   JOIN_TAB *tmp_join_tab= join->join_tab+join->tables;
   THD *thd= join->thd;
   LEX *lex= thd->lex;
-  bool result= 0;
   DBUG_ENTER("get_schema_tables_result");
 
   thd->no_warnings_for_error= 1;
@@ -3930,12 +3930,15 @@
 
       if (table_list->schema_table->fill_table(thd, table_list,
                                                tab->select_cond))
-        result= 1;
+      {
+        push_warning(thd, MYSQL_ERROR::WARN_LEVEL_WARN,
+                     thd->net.last_errno, thd->net.last_error);
+        thd->clear_error();
+      }
       table_list->is_schema_table_processed= TRUE;
     }
   }
   thd->no_warnings_for_error= 0;
-  DBUG_RETURN(result);
 }
 
 
Thread
bk commit into 5.0 tree (kroki:1.2192) BUG#16581kroki23 Jun