diff options
author | petr/cps@owlet.local <> | 2006-09-28 04:44:55 +0400 |
---|---|---|
committer | petr/cps@owlet.local <> | 2006-09-28 04:44:55 +0400 |
commit | 64c2c0cb19f17d1d78c0d6f7cadf70a1a4eda9ec (patch) | |
tree | 74cc2cd6212441cc4db3e8cec9413899670cca51 /sql/sp.cc | |
parent | 5e2f69d1ddda97c2de3d4c9cb52282e81cb518c1 (diff) | |
parent | 6cb96bb8b4b23a86a38ebb691654e296e6505fc5 (diff) | |
download | mariadb-git-64c2c0cb19f17d1d78c0d6f7cadf70a1a4eda9ec.tar.gz |
Merge pchardin@bk-internal.mysql.com:/home/bk/mysql-5.1
into mysql.com:/home/cps/mysql/trees/5.1-runtime-new
Diffstat (limited to 'sql/sp.cc')
-rw-r--r-- | sql/sp.cc | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/sql/sp.cc b/sql/sp.cc index 7ae335a1a3d..8ddf55e1837 100644 --- a/sql/sp.cc +++ b/sql/sp.cc @@ -65,8 +65,6 @@ enum MYSQL_PROC_FIELD_COUNT }; -bool mysql_proc_table_exists= 1; - /* Tells what SP_DEFAULT_ACCESS should be mapped to */ #define SP_DEFAULT_ACCESS_MAPPING SP_CONTAINS_SQL @@ -118,13 +116,6 @@ TABLE *open_proc_table_for_read(THD *thd, Open_tables_state *backup) bool not_used; DBUG_ENTER("open_proc_table"); - /* - Speed up things if mysql.proc doesn't exists. mysql_proc_table_exists - is set when we create or read stored procedure or on flush privileges. - */ - if (!mysql_proc_table_exists) - DBUG_RETURN(0); - thd->reset_n_backup_open_tables_state(backup); bzero((char*) &tables, sizeof(tables)); @@ -134,7 +125,6 @@ TABLE *open_proc_table_for_read(THD *thd, Open_tables_state *backup) MYSQL_LOCK_IGNORE_FLUSH))) { thd->restore_backup_open_tables_state(backup); - mysql_proc_table_exists= 0; DBUG_RETURN(0); } table->use_all_columns(); @@ -186,15 +176,6 @@ static TABLE *open_proc_table_for_update(THD *thd) if (table) table->use_all_columns(); - /* - Under explicit LOCK TABLES or in prelocked mode we should not - say that mysql.proc table does not exist if we are unable to - open and lock it for writing since this condition may be - transient. - */ - if (!(thd->locked_tables || thd->prelocked_mode) || table) - mysql_proc_table_exists= test(table); - DBUG_RETURN(table); } @@ -1610,14 +1591,6 @@ sp_cache_routines_and_add_tables_aux(THD *thd, LEX *lex, case SP_KEY_NOT_FOUND: ret= SP_OK; break; - case SP_OPEN_TABLE_FAILED: - /* - Force it to attempt opening it again on subsequent calls; - otherwise we will get one error message the first time, and - then ER_SP_PROC_TABLE_CORRUPT (below) on subsequent tries. - */ - mysql_proc_table_exists= 1; - /* Fall through */ default: /* Any error when loading an existing routine is either some problem |