summaryrefslogtreecommitdiff
path: root/sql/sql_yacc.yy
diff options
context:
space:
mode:
authorserg@serg.mylan <>2004-03-16 16:35:47 +0100
committerserg@serg.mylan <>2004-03-16 16:35:47 +0100
commitceec63f18aa0c2e4ee9c5f667cca3f1ffdeda15d (patch)
treea14f2d0da18b76c70fcf4ce8e3601d0014a43def /sql/sql_yacc.yy
parente970ff9e87ab1b9eb6e66f9deff9522ac6af3fdf (diff)
downloadmariadb-git-ceec63f18aa0c2e4ee9c5f667cca3f1ffdeda15d.tar.gz
EOVERFLOW moved to my_base.h - it is used not only in strtod.c
error message corrected
Diffstat (limited to 'sql/sql_yacc.yy')
-rw-r--r--sql/sql_yacc.yy10
1 files changed, 8 insertions, 2 deletions
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 0f9147b7834..a625040d4e2 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -2508,7 +2508,7 @@ simple_expr:
$$= new Item_func_set_collation($1,
new Item_string($3.str,
$3.length,
- YYTHD->charset()));
+ YYTHD->charset()));
}
| literal
| param_marker
@@ -2524,6 +2524,12 @@ simple_expr:
}
| '@' '@' opt_var_ident_type ident_or_text opt_component
{
+
+ if ($4.str && $5.str && check_reserved_words(&$4))
+ {
+ yyerror(ER(ER_SYNTAX_ERROR));
+ YYABORT;
+ }
if (!($$= get_system_var(YYTHD, (enum_var_type) $3, $4, $5)))
YYABORT;
}
@@ -5036,7 +5042,7 @@ internal_variable_name:
{
if (check_reserved_words(&$1))
{
- net_printf(YYTHD, ER_SYNTAX_ERROR);
+ yyerror(ER(ER_SYNTAX_ERROR));
YYABORT;
}
sys_var *tmp=find_sys_var($3.str, $3.length);