Skip to content

Commit 1f5fc7b

Browse files
committed
MDEV-27208: mtr --ps-protocol test fixup
The test ./mtr --ps-protocol main.func_math was broken in commit 5b3ad94 because in that mode, one of several truncation warnings for a single integer literal would be omitted. Those warnings are issued by the parser somewhere outside CRC32() or CRC32C().
1 parent 5b3ad94 commit 1f5fc7b

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

mysql-test/main/func_math.result

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1931,6 +1931,9 @@ x
19311931
Warnings:
19321932
Warning 1916 Got overflow when converting '' to DECIMAL. Value truncated
19331933
Warning 1916 Got overflow when converting '99999999999999999999999999999999999999999999999999999999999999999' to INT. Value truncated
1934+
select crc32(429496729656755555555555555555555555555555555555555555555555555555555555555555555555555,'a') as x;
1935+
x
1936+
3310005809
19341937
DROP TABLE IF EXISTS t;
19351938
Warnings:
19361939
Note 1051 Unknown table 'test.t'

mysql-test/main/func_math.test

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -891,7 +891,12 @@ select crc32(1e100,''), hex(char(1e100));
891891
select crc32(10.11,''), hex(char(10.11));
892892
select crc32(-1,''), hex(char(-1));
893893
select crc32('',''), hex(char(''));
894+
--disable_ps_protocol
894895
select crc32(429496729656755555555555555555555555555555555555555555555555555555555555555555555555555,'a') as x;
896+
--enable_ps_protocol
897+
--disable_warnings
898+
select crc32(429496729656755555555555555555555555555555555555555555555555555555555555555555555555555,'a') as x;
899+
--enable_warnings
895900

896901
# Test cases for using the function in aggregate functions, group-by, having
897902
# and order-by clauses

0 commit comments

Comments
 (0)