Below is the list of changes that have just been committed into a local
5.0 repository of mydev. When mydev 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.1944 05/06/01 13:22:17 ingo@stripped +3 -0
Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
After merge fixes.
sql/sql_yacc.yy
1.386 05/06/01 13:20:42 ingo@stripped +5 -4
Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
After merge fixes.
sql/sql_parse.cc
1.443 05/06/01 13:20:42 ingo@stripped +12 -2
Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
After merge fixes.
sql/sql_base.cc
1.249 05/06/01 13:20:42 ingo@stripped +1 -1
Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
After merge fixes.
# 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: ingo
# Host: chilla.local
# Root: /home/mydev/mysql-5.0-5000
--- 1.248/sql/sql_base.cc Wed Jun 1 11:15:16 2005
+++ 1.249/sql/sql_base.cc Wed Jun 1 13:20:42 2005
@@ -1384,7 +1384,7 @@
MYSQL_LOCK *lock;
/* We should always get these locks */
thd->some_tables_deleted=0;
- if ((lock= mysql_lock_tables(thd, tables, (uint) (tables_ptr-tables), 0)))
+ if ((lock= mysql_lock_tables(thd, tables, (uint) (tables_ptr - tables), 0)))
{
thd->locked_tables=mysql_lock_merge(thd->locked_tables,lock);
}
--- 1.442/sql/sql_parse.cc Wed Jun 1 11:15:16 2005
+++ 1.443/sql/sql_parse.cc Wed Jun 1 13:20:42 2005
@@ -2808,7 +2808,7 @@
unique_table(create_table, select_tables))
{
my_error(ER_UPDATE_TABLE_USED, MYF(0), create_table->table_name);
- goto unsent_create_error;
+ goto unsent_create_error1;
}
/* If we create merge table, we have to test tables in merge, too */
if (lex->create_info.used_fields & HA_CREATE_USED_UNION)
@@ -2821,7 +2821,7 @@
if (unique_table(tab, select_tables))
{
my_error(ER_UPDATE_TABLE_USED, MYF(0), tab->table_name);
- goto unsent_create_error;
+ goto unsent_create_error1;
}
}
}
@@ -2872,6 +2872,13 @@
lex->link_first_table_back(create_table, link_to_local);
break;
+unsent_create_error1:
+ /*
+ Release the protection against the global read lock and wake
+ everyone, who might want to set a global read lock.
+ */
+ start_waiting_global_read_lock(thd);
+
/* put tables back for PS rexecuting */
unsent_create_error:
lex->link_first_table_back(create_table, link_to_local);
@@ -6959,6 +6966,8 @@
{
/* Check permissions for used tables in CREATE TABLE ... SELECT */
+#ifdef NOT_NECESSARY_TO_CHECK_CREATE_TABLE_EXIST_WHEN_PREPARING_STATEMENT
+ /* This code throws an ill error for CREATE TABLE t1 SELECT * FROM t1 */
/*
Only do the check for PS, becasue we on execute we have to check that
against the opened tables to ensure we don't use a table that is part
@@ -6977,6 +6986,7 @@
goto err;
}
}
+#endif
if (tables && check_table_access(thd, SELECT_ACL, tables,0))
goto err;
}
--- 1.385/sql/sql_yacc.yy Wed Jun 1 10:52:59 2005
+++ 1.386/sql/sql_yacc.yy Wed Jun 1 13:20:42 2005
@@ -7083,12 +7083,13 @@
TABLE_LIST *table= (TABLE_LIST*) Select->table_list.first;
if (my_strcasecmp(table_alias_charset, $1.str, table->db))
{
- net_printf(YYTHD, ER_WRONG_DB_NAME, $1.str);
+ my_error(ER_WRONG_DB_NAME, MYF(0), $1.str);
YYABORT;
}
- if (my_strcasecmp(table_alias_charset, $3.str, table->real_name))
+ if (my_strcasecmp(table_alias_charset, $3.str,
+ table->table_name))
{
- net_printf(YYTHD, ER_WRONG_TABLE_NAME, $3.str);
+ my_error(ER_WRONG_TABLE_NAME, MYF(0), $3.str);
YYABORT;
}
$$=$5;
@@ -7098,7 +7099,7 @@
TABLE_LIST *table= (TABLE_LIST*) Select->table_list.first;
if (my_strcasecmp(table_alias_charset, $1.str, table->alias))
{
- net_printf(YYTHD, ER_WRONG_TABLE_NAME, $1.str);
+ my_error(ER_WRONG_TABLE_NAME, MYF(0), $1.str);
YYABORT;
}
$$=$3;
| Thread |
|---|
| • bk commit into 5.0 tree (ingo:1.1944) BUG#10224 | ingo | 1 Jun |