1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Trimmed fix for bug #9546 (Crashing with huge decimals)

mysql-test/r/type_newdecimal.result:
  test result fixed
mysql-test/t/type_newdecimal.test:
  test case added
sql/my_decimal.cc:
  error message fixed
strings/decimal.c:
  do_add function fixed
This commit is contained in:
unknown
2005-05-06 19:04:58 +05:00
parent 0430cdb7c5
commit f1def25a89
4 changed files with 27 additions and 4 deletions

View File

@ -846,3 +846,14 @@ set sql_mode='';
select 0/0;
0/0
NULL
select 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 as x;
x
999999999999999999999999999999999999999999999999999999999999999999999999999999999
Warnings:
Error 1292 Truncated incorrect DECIMAL value: ''
select 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 + 1 as x;
x
NULL
Warnings:
Error 1292 Truncated incorrect DECIMAL value: ''
Error 1292 Truncated incorrect DECIMAL value: ''

View File

@ -876,3 +876,9 @@ select 10.3330000000000/12.34500000;
set sql_mode='';
select 0/0;
#
# bug #9546
#
select 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 as x;
select 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 + 1 as x;