If mariadb_stmt_execute_direct fails, we need to set the number
of parameters (obtained by response packet of mysql_stmt_prepare)
back to the number of prebinded parameters to avoid memory
overrun.
This fix also includes several adress-sanitizer bugs in unit tests
of Connector/C.
If cursor type is set to read only, and SERVER_STATUS_CURSOR_EXISTS
flag was not set in the server_status of EOF packet, the assumption
was made that a single result set will follow which will be stored
by a call to mysql_stmt_store_result().
As the example in the bug report shows, this is not always the case,
since a stored procedure call might also unset the CURSOR flag and
will always return multiple result sets. In this case it will be
handled now as "normal" unbuffered result set.
travis: use connector-test-machine test script that permit to run the following tests :
* MariaDB all supported version
* Maxscale
* MySQL
* SkySQL
If CONNECTOR_TEST_SECRET_KEY is not provided (PR) only MariaDB and MySQL community will be test
Pull request testing correction
appveyor correction using archive if not latest server release
With implementation of MDEV-16708 (support all commands in binary protocol) we
need to check for local infile in text and binary protocol. Therefore the local
infile relevant part from ma_simple_command was moved to mthd_my_send_cmd method.
While in text protocol the number of rows is resetted in mysql_store/use_result
in binary protocol we need to explicitly reset it when switching to next result set.
1) In case a cursor is used in a stored procedure server sends a SERVER_STATUS_CURSOR_EXISTS flag,
even if the client didn't open a cursor via mysql_stmt_attr_set. This ends in a "comands out of sync" error,
since the client is sending a COM_STMT_FETCH command while the result sets were not read before.
We check now in case server sends a SERVER_STATUS_CURSOR_EXIST flag, if the client opened a cursor before.
2) The stmt error codes weren't update for all COM_STMT* commands correctly, e.g. COM_STMT_FETCH didn't show an error even if it failed.
if the length of the provided result buffer is equal or smaller than the converted number and
ZEROFILL FLAG is set, a truncation error will be reported.
Fix a regression in new my_atoll()/my_atoull()
to set error, if there are non-digits found in the string.
Spaces at the start and end of string are ignored (however, not between the
digits).
Fix implementations of str_to_TIME() and my_atoll()
Implement own version my_strtoll() (similar to strtoull(), not requiring
null termination).
Use it to for optimized implementation of numbers and dates.
with some compilers(observed with VS). That would happen in memcmp of 2 MYSQL_TIME structures. Apparently because different
content of memory areas the compiler used to pad structures.
libmariadb\libmariadb\ma_stmt_codec.c(263): warning C4244: '*=': conversion from 'double' to 'unsigned long', possible loss of data
generally avoid slow floating point pow() when all you need is to
multiply an integer by a small power of 10.
If a datetime or time value is represented a a string and has a fractional part with less than 6 digits,
it should be interpreted as a 6-digit representation:
.9 becomes 900000
.09 becomes 90000
etc.
- added support for negative time values
- invalid strings (and/or conversion) and invalid values will result in MYSQL_TIMESTAMP_ERROR time type
- added support for 2digit year representation:
values < 69 will be converted to 20YY
values >= 69 will be converted to 19YY