1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-08-08 14:02:17 +03:00

605 Commits

Author SHA1 Message Date
Georg Richter
61a2ae2705 Merge branch '3.1' into 3.2 2021-07-26 18:05:17 +02:00
Georg Richter
9c651bd678 CONC-565: Incorrect max_length in binary protocol
Fixed max_length values in ma_stmt_codecs for integer types:
- all types included an extra byte for trailing zero character
- maximum value for year column type is 2155 (and not 0xFFFF).
2021-07-26 17:47:37 +02:00
Marko Mäkelä
490100ccac CONC-49 fixup
test_conc49(): Do not leak memory.
2021-07-22 15:55:45 +03:00
Georg Richter
7e6ae832bd removed aurora test:
aurora plugin was removed in C/C 3.2.0
2021-07-20 17:24:10 +02:00
Vladislav Vaintroub
7d3d7c5ff4 Fix GCC's "ISO C90 forbids mixed declarations and code" 2021-07-20 10:55:07 +02:00
Georg Richter
4853464ed2 Test case fixes:
- remove table af end of test
- fixed memory leak (missing mysql_free_result)
2021-07-09 06:38:28 +02:00
Sergei Golubchik
fffa8167d8 ISO C90 forbids mixed declarations and code 2021-07-05 12:43:06 +02:00
Georg Richter
16a031945a Merge branch '3.1' into 3.2 2021-06-24 16:49:15 +02:00
Georg Richter
d111980380 Fix for MDEV-25820:
Tests will be skipped unless the following environment variables
were specified:

- MYSQLTEST_VARDIR (will be automatically set when running inside
  mtr)
- MARIADB_CC_TEST
2021-06-24 16:44:21 +02:00
Georg Richter
9661ddaefb Fixed compiler warnings (introduced by changeset b78ba1b251) 2021-06-24 15:05:08 +02:00
Georg Richter
353e99fba1 More test fixes 2021-06-24 12:48:16 +02:00
Georg Richter
47df15edb6 Fixed compiler warnings (introduced by changeset b78ba1b251) 2021-06-24 11:27:07 +02:00
kolzeq
25e38080cb Merge branch '3.1' into 3.2-diego
# Conflicts:
#	.travis.yml
#	unittest/libmariadb/charset.c
#	unittest/libmariadb/connection.c
2021-06-17 10:54:30 +02:00
Georg Richter
85c3742252 Follow up of dec061fa95
Use EVP_PKEY_set1_RSA() instead of EVP_PKEY_assign_RSA, since
the public key will be freed when releasing pkey-
2021-06-16 16:13:14 +02:00
kolzeq
94e85cdd4b testing various correction
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
2021-06-15 17:09:10 +02:00
Georg Richter
ea4e47f41a Merge branch '3.1' into 3.2 2021-06-10 17:37:48 +02:00
Georg Richter
aca697e5a1 Travis test fixes
Since 10.6 server returns utf8mb3 for character set (and it will change
to utf8mb4), so we use strncmp to check the character set returned by
server.
2021-06-09 07:29:56 +02:00
pasha-bolokhov
6710f59817 Update async.c
Typo fix
2021-05-17 07:54:50 -07:00
Georg Richter
e4e5b28452 CONC-533: Support for asynchronous statements (binary protocol)
Added a new option MARIADB_OPT_SKIP_READ_RESPONSE which skips automatic
reading of server response after sending a command to the server.

Server packets have to be retrieved by calling the corresponding methods,
e.g:

Send command                         Read method
mysql_real_query/mysql_send_query    db_read_query_result
mysql_stmt_prepare                   db_read_prepare_response
mysql_stmt_execute,
mariadb_stmt_execute_direct          db_read_execute_response
2021-05-13 21:21:43 +02:00
Georg Richter
01ada4b85f Merge branch '3.1' into 3.2 2021-05-03 14:01:37 +02:00
Georg Richter
9244281d6b Fix for CONC-490:
If CLIENT_CONNECT_WITH_DB flag was specified without a database name,
we need to unset this flag to prevent breaking connection handshake.
2021-04-29 10:59:25 +02:00
Rucha Deodhar
2f7230c62b MDEV-8334: Rename utf8 to utf8mb3
This patch is made as a part of MDEV-8334 to fix failing test in unit and
main test suite so that utf8mb3 characterset is recognized. Failing tests:
main.mysql_client_test
main.mysql_client_test_comp
unit.conc_basic-t
unit.conc_charset
unit.conc_connection
2021-04-17 02:10:25 +05:30
Vladislav Vaintroub
b6f8883d96 CONC-534 memory leak in ps_bugs.c 2021-03-15 20:07:28 +01:00
Georg Richter
b21c39c001 Merge branch '3.1' into 3.2 2021-03-14 12:03:07 +01:00
Georg Richter
56497646b7 Disable failing tests when running against MaxScale. 2021-03-14 11:53:28 +01:00
Georg Richter
ca1ea5c1a2 Fix for CONC-525: Support LOAD * LOCAL INFILE statements in binary protocol
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.
2021-02-23 07:55:35 +01:00
Georg Richter
67cd96f141 Revert "CONC-142: Fix memory leak in connection"
This reverts commit 63a207e790.
2021-02-09 20:27:52 +01:00
Georg Richter
63a207e790 CONC-142: Fix memory leak in connection
When closing connection object the reference of server_version_info
needs to be decremented to prevent memory leakage.
2021-02-09 20:25:55 +01:00
Oleksandr Byelkin
e62ff462c5 fix memory leack in the test 2021-01-28 11:20:35 +01:00
Oleksandr Byelkin
e21d21d71f Fix ASAN issues in the tests 2021-01-27 20:25:13 +01:00
Oleksandr Byelkin
b503e52288 fix problems found by 10.0 2021-01-27 13:13:31 +01:00
Anton Golovenko
f52582d1f8 unittests fix 2021-01-20 19:07:38 +05:00
Anton Golovenko
a7e888b518 Test bugs fixes 2021-01-20 18:54:55 +05:00
kolzeq
29fc3bc7bd [misc] test improvement
* adding SkySQL HA to test suite
* test server build 10.6
* test maxscale 2.5.3
2021-01-19 10:23:14 +01:00
Georg Richter
820faff627 codespell fixes, removed MSDOS preprocessor macros 2020-11-26 09:07:17 +01:00
Georg Richter
88e9d172b4 Added missing test case for CONC-512 2020-11-08 14:52:42 +01:00
Georg Richter
03948821ae Test fix:
Drop procedure at end of test.
2020-10-28 10:58:05 +01:00
Marko Mäkelä
0cdc1656a7 Do not leak memory in the skipped MDEV-23768 unit test 2020-10-24 11:07:47 +03:00
Georg Richter
8a4fac7f22 unittest fix:
Added macro SKIP_NOTLS for skipping tests if MariaDB Connector/C
was build without TLS support.
2020-10-23 06:39:15 +02:00
Georg Richter
b24d337027 More test fixes:
Always provide a message to the FAIL_ macros
2020-10-20 16:17:25 +02:00
Georg Richter
dec58668dd Test fix (appveyor):
Don't use hardcoded schema name, since default schema can be set via
environment variable (or option).
2020-10-20 15:25:05 +02:00
Georg Richter
55a64c1bd5 Fix for CONC-504: reset stmt->result.rows when executing mysql_stmt_next_result
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.
2020-10-02 09:47:52 +02:00
Georg Richter
aa65bd1beb Skip test_returning, since it's not fixed on server yet (MDEV-23768) 2020-09-21 18:25:10 +02:00
Georg Richter
8752eea4f2 Use a newer ubuntu version for travis 2020-09-21 15:44:05 +02:00
Georg Richter
7052619cc4 Added build option WITH_ICONV.
Default is OFF, which means MariaDB Connector/C
will be built without iconv support.

If set to OFF The API function mariadb_convert_string will always
return -1 and errorcode ENOTSUP.
2020-09-14 12:01:06 +02:00
Georg Richter
29a3396456 CONC-302: Added support for SESSION_TRACK_GTIDS (MySQL server) 2020-09-12 10:58:33 +02:00
Georg Richter
2c22f8e71b Don't test session tracking for character set against server < 10.3 2020-09-10 17:27:39 +02:00
Georg Richter
a17e73f953 Skip test_conc496 if session_tracking_transaction_info variable is not available/supported. 2020-09-10 16:30:04 +02:00
Georg Richter
3e699a1738 CONC-496: Added support for SESSION_TRACK_TRANSACTION_STATE in ok packet 2020-09-10 14:03:00 +02:00
Georg Richter
01859950cf Revert "Fix for CONC-494:"
This reverts commit 8581cafad4.
2020-09-09 12:19:27 +02:00