summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjcole@tetra.spaceapes.com <>2001-03-14 01:18:16 -0600
committerjcole@tetra.spaceapes.com <>2001-03-14 01:18:16 -0600
commit1b9ce04050df537888d50a53eeccbe39079e45bb (patch)
tree8cce67ce74fd018d592134d364422581dd5ac55d
parent555430819d7a35d32691fd74d8005f666ae1907c (diff)
downloadmariadb-git-1b9ce04050df537888d50a53eeccbe39079e45bb.tar.gz
Moved state_map copying to THD::THD().
-rw-r--r--sql/sql_class.cc4
-rw-r--r--sql/sql_lex.cc2
-rw-r--r--sql/sql_parse.cc4
3 files changed, 5 insertions, 5 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc
index 1bced49be57..24a48604da2 100644
--- a/sql/sql_class.cc
+++ b/sql/sql_class.cc
@@ -133,6 +133,10 @@ THD::THD():user_time(0),fatal_error(0),last_insert_id_used(0),
}
#endif
+ // copy global state map into thread
+ for(int x=0; x < 256; x++)
+ state_map[x] = global_state_map[x];
+
#ifdef __WIN__
real_id = 0 ;
#endif
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc
index 5e75339b0db..f0357b99d70 100644
--- a/sql/sql_lex.cc
+++ b/sql/sql_lex.cc
@@ -425,7 +425,7 @@ int yylex(void *arg)
uint length;
enum lex_states state,prev_state;
LEX *lex=current_lex;
- uchar *state_map = global_state_map; // thd->lex->state_map;
+ uchar *state_map = lex->thd->state_map;
YYSTYPE *yylval=(YYSTYPE*) arg;
lex->yylval=yylval; // The global state
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc
index 6ddb3b45864..1884a8825ba 100644
--- a/sql/sql_parse.cc
+++ b/sql/sql_parse.cc
@@ -512,10 +512,6 @@ pthread_handler_decl(handle_one_connection,arg)
return 0;
}
- // copy global state map into thread
- for(int x=0; x < 256; x++)
- thd->state_map[x] = global_state_map[x];
-
do
{
int error;