MDEV-22545: my_vsnprintf behaves not as in C standard

Added parameter %T for string which should be visibly truncated.
This commit is contained in:
Oleksandr Byelkin 2020-05-20 13:34:51 +02:00
commit cf52dd174e
10 changed files with 267 additions and 223 deletions

View file

@ -2,6 +2,6 @@ MySQL error code 150: Foreign key constraint is incorrectly formed
Win32 error code 150: System trace information was not specified in your CONFIG.SYS file, or tracing is disallowed.
OS error code 23: Too many open files in system
Win32 error code 23: Data error (cyclic redundancy check).
MySQL error code 1062 (ER_DUP_ENTRY): Duplicate entry '%-.192s' for key %d
MySQL error code 1062 (ER_DUP_ENTRY): Duplicate entry '%-.192T' for key %d
Win32 error code 1062: The service has not been started.
Illegal error code: 30000

View file

@ -1,5 +1,5 @@
Illegal error code: 10000
MySQL error code 1062 (ER_DUP_ENTRY): Duplicate entry '%-.192s' for key %d
MySQL error code 1062 (ER_DUP_ENTRY): Duplicate entry '%-.192T' for key %d
MySQL error code 1408 (ER_STARTUP): %s: ready for connections.
Version: '%s' socket: '%s' port: %d %s
MySQL error code 1459 (ER_TABLE_NEEDS_UPGRADE): Upgrade required. Please do "REPAIR %s %`s" or dump/reload to fix it!

View file

@ -11,7 +11,7 @@ drop table t1;
connection slave;
include/wait_for_slave_sql_to_stop.inc
call mtr.add_suppression("Slave SQL.*Query caused different errors on master and slave.*Error on master:.* error code=1062.*Error on slave:.* error.* 0");
Error: "Query caused different errors on master and slave. Error on master: message (format)='Duplicate entry '%-.192s' for key %d' error code=1062 ; Error on slave: actual message='no error', error code=0. Default database: 'test'. Query: 'insert into t1 values(1),(2)'" (expected different error codes on master and slave)
Error: "Query caused different errors on master and slave. Error on master: message (format)='Duplicate entry '%-.192T' for key %d' error code=1062 ; Error on slave: actual message='no error', error code=0. Default database: 'test'. Query: 'insert into t1 values(1),(2)'" (expected different error codes on master and slave)
Errno: "0" (expected 0)
drop table t1;
include/stop_slave.inc