mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Merge
This commit is contained in:
@@ -1420,6 +1420,8 @@ Item *Item_func_case::find_item(String *str)
|
||||
my_decimal *first_expr_dec, first_expr_dec_val;
|
||||
longlong first_expr_int;
|
||||
double first_expr_real;
|
||||
char buff[MAX_FIELD_WIDTH];
|
||||
String buff_str(buff,sizeof(buff),default_charset());
|
||||
|
||||
/* These will be initialized later */
|
||||
LINT_INIT(first_expr_str);
|
||||
@@ -1433,7 +1435,7 @@ Item *Item_func_case::find_item(String *str)
|
||||
{
|
||||
case STRING_RESULT:
|
||||
// We can't use 'str' here as this may be overwritten
|
||||
if (!(first_expr_str= args[first_expr_num]->val_str(&str_value)))
|
||||
if (!(first_expr_str= args[first_expr_num]->val_str(&buff_str)))
|
||||
return else_expr_num != -1 ? args[else_expr_num] : 0; // Impossible
|
||||
break;
|
||||
case INT_RESULT:
|
||||
|
||||
Reference in New Issue
Block a user