summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbell@sanja.is.com.ua <>2002-11-23 23:21:49 +0200
committerbell@sanja.is.com.ua <>2002-11-23 23:21:49 +0200
commitc8d8367021ddb29781b5854c0bd171c7d53cff7f (patch)
treea9a38b9faa223bcec515e2780fb37af8c4cbeb7f
parentd6b646d4fc14352d699002082422ba96d2ce63d2 (diff)
downloadmariadb-git-c8d8367021ddb29781b5854c0bd171c7d53cff7f.tar.gz
revert open_ltable changing
-rw-r--r--sql/mysql_priv.h3
-rw-r--r--sql/sql_base.cc17
2 files changed, 6 insertions, 14 deletions
diff --git a/sql/mysql_priv.h b/sql/mysql_priv.h
index a92893ca142..3ba88d493bd 100644
--- a/sql/mysql_priv.h
+++ b/sql/mysql_priv.h
@@ -448,8 +448,7 @@ void kill_delayed_threads(void);
int mysql_delete(THD *thd, TABLE_LIST *table, COND *conds, ORDER *order,
ha_rows rows, ulong options);
int mysql_truncate(THD *thd, TABLE_LIST *table_list, bool dont_send_ok=0);
-TABLE *open_ltable(THD *thd, TABLE_LIST *table_list, thr_lock_type update,
- bool multiopen= 0);
+TABLE *open_ltable(THD *thd, TABLE_LIST *table_list, thr_lock_type update);
TABLE *open_table(THD *thd,const char *db,const char *table,const char *alias,
bool *refresh);
TABLE *reopen_name_locked_table(THD* thd, TABLE_LIST* table);
diff --git a/sql/sql_base.cc b/sql/sql_base.cc
index 4c6192bc694..5655225cea3 100644
--- a/sql/sql_base.cc
+++ b/sql/sql_base.cc
@@ -1615,24 +1615,17 @@ static bool check_lock_and_start_stmt(THD *thd, TABLE *table,
table_list->table table
*/
-TABLE *open_ltable(THD *thd, TABLE_LIST *table_list, thr_lock_type lock_type,
- bool multiopen)
+TABLE *open_ltable(THD *thd, TABLE_LIST *table_list, thr_lock_type lock_type)
{
TABLE *table;
bool refresh;
DBUG_ENTER("open_ltable");
thd->proc_info="Opening table";
- if (table_list->next && multiopen)
- {
- while (open_tables(thd,table_list) && refresh) ;
- table= table_list->table;
- }
- else
- while (!(table= open_table(thd,table_list->db,
- table_list->real_name,table_list->alias,
- &refresh)) && refresh) ;
-
+ while (!(table=open_table(thd,table_list->db,
+ table_list->real_name,table_list->alias,
+ &refresh)) && refresh) ;
+
if (table)
{
#if defined( __WIN__) || defined(OS2)