summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorunknown <sasha@mysql.sashanet.com>2001-09-10 17:30:29 -0600
committerunknown <sasha@mysql.sashanet.com>2001-09-10 17:30:29 -0600
commit8cfd4949c2725431d78605d30c1138c4d42ab4d2 (patch)
tree16ba4457be345a16fce35898ee96bb1c1248d0ef /sql
parente7006ae7946f2fd0cf3ea30aeab7eb974e769a4d (diff)
downloadmariadb-git-8cfd4949c2725431d78605d30c1138c4d42ab4d2.tar.gz
fixed IDENTITY crisis
Diffstat (limited to 'sql')
-rw-r--r--sql/sql_lex.cc16
1 files changed, 13 insertions, 3 deletions
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc
index 20bda932f2f..e0044a0710f 100644
--- a/sql/sql_lex.cc
+++ b/sql/sql_lex.cc
@@ -793,9 +793,19 @@ int yylex(void *arg)
}
break;
case STATE_USER_END: // end '@' of user@hostname
- if (state_map[yyPeek()] != STATE_STRING &&
- state_map[yyPeek()] != STATE_USER_VARIABLE_DELIMITER)
- lex->next_state=STATE_HOSTNAME; // Mark for next loop
+ switch (state_map[yyPeek()])
+ {
+ case STATE_STRING:
+ case STATE_USER_VARIABLE_DELIMITER:
+ break;
+ case STATE_USER_END:
+ lex->next_state=STATE_USER_END;
+ yySkip();
+ break;
+ default:
+ lex->next_state=STATE_HOSTNAME;
+ break;
+ }
yylval->lex_str.str=(char*) lex->ptr;
yylval->lex_str.length=1;
return((int) '@');