mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
different (simpler and more compatible) fix for bug#4046
This commit is contained in:
@ -3157,7 +3157,10 @@ bool add_field_to_list(char *field_name, enum_field_types type,
|
||||
break;
|
||||
case FIELD_TYPE_DECIMAL:
|
||||
if (!length)
|
||||
new_field->length= 10; // Default length for DECIMAL
|
||||
if (new_field->length= new_field->decimals)
|
||||
new_field->length++;
|
||||
else
|
||||
new_field->length=10; // Default length for DECIMAL
|
||||
if (new_field->length < MAX_FIELD_WIDTH) // Skip wrong argument
|
||||
{
|
||||
new_field->length+=sign_len;
|
||||
|
Reference in New Issue
Block a user