1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-05 12:42:17 +03:00
Commit Graph

943 Commits

Author SHA1 Message Date
a206658b98 Change CHARSET_INFO character set and collaction names to LEX_CSTRING
This change removed 68 explict strlen() calls from the code.

The following renames was done to ensure we don't use the old names
when merging code from earlier releases, as using the new variables
for print function could result in crashes:
- charset->csname renamed to charset->cs_name
- charset->name renamed to charset->coll_name

Almost everything where mechanical changes except:
- Changed to use the new Protocol::store(LEX_CSTRING..) when possible
- Changed to use field->store(LEX_CSTRING*, CHARSET_INFO*) when possible
- Changed to use String->append(LEX_CSTRING&) when possible

Other things:
- There where compiler issues with ensuring that all character set names
  points to the same string: gcc doesn't allow one to use integer constants
  when defining global structures (constant char * pointers works fine).
  To get around this, I declared defines for each character set name
  length.
2021-05-19 22:54:07 +02:00
2fdb556e04 MDEV-8334: Rename utf8 to utf8mb3
This patch changes the main name of 3 byte character set from utf8 to
utf8mb3. New old_mode UTF8_IS_UTF8MB3 is added and set TRUE by default,
so that utf8 would mean utf8mb3. If not set, utf8 would mean utf8mb4.
2021-05-19 06:48:36 +02:00
356c149603 Merge 10.5 into 10.6 2021-03-26 11:50:32 +02:00
cebf9ee204 Fix various spelling errors still found in code
Reseting -> Resetting
Unknow -> Unknown
capabilites -> capabilities
choosen -> chosen
direcory -> directory
informations -> information
openned -> opened
refered -> referred
to access -> one to access
missmatch -> mismatch
succesfully -> successfully
dont -> don't
2021-03-22 18:10:39 +11:00
09a1f0075a Merge 10.5 into 10.6 2020-11-02 12:49:19 +02:00
25ede13611 Merge branch '10.4' into 10.5 2020-09-29 16:59:36 +05:30
ce845b7a2f Merge branch '10.3' into 10.4 2020-09-28 17:55:39 +05:30
6cbbd6bd96 Merge branch '10.2' into 10.3 2020-09-28 17:27:42 +05:30
70960bd33d UBSAN: Fix a bit shift overflow
Shifting a 16-bit type by 16 bits is undefined behaviour.
The result is at least 32 bits, so let us cast the shift operand
to a wider type before shifting.
2020-09-23 12:42:30 +03:00
5edf3e0388 Merge branch '10.5' into 10.6 2020-09-02 14:36:14 +02:00
32a29afea7 MDEV-23238 - remove async client from server code.
It is already in libmariadb, and server (also that client in server)
does not need it.

It does not work in embedded either since it relies on non-blocking sockets
2020-09-01 21:30:52 +02:00
b01c426146 MDEV-19275 Provide SQL service to plugins.
Protocol_local fixed so it can be used now.
Some Protocol:: methods made virtual so they can adapt.
as well as net_ok and net_send_error functions.
execute_sql_string function is exported to the plugins.
To be changed with the mysql_use_result.
2020-08-14 21:04:25 +04:00
50a11f396a Merge 10.4 into 10.5 2020-08-01 14:42:51 +03:00
9216114ce7 Merge 10.3 into 10.4 2020-07-31 18:09:08 +03:00
66ec3a770f Merge 10.2 into 10.3 2020-07-31 13:51:28 +03:00
b3dd95e035 MDEV-14203: rpl.rpl_extra_col_master_myisam, rpl.rpl_slave_load_tmpdir_not_exist failed in buildbot with a warning
Problem:
=======
rpl.rpl_slave_load_tmpdir_not_exist 'stmt' w3 [ fail ]  Found warnings/errors
in server log file!

Test ended at 2017-09-27 20:34:55
[Warning] Master is configured to log replication events with checksum, but
will not send such events to slaves that cannot process them
^ Found warnings in /mnt/buildbot/build/mariadb-10.2.10/mysql-test/var/3/log/mysqld.1.err
ok
Analysis:
========
When slave tries to connect to master 'get_master_version_and_clock' function
is invoked to perform elaborated slave-master handshake. During this process
slave server queries master server, to know if it is checksum aware and at the
same time master is notified about its CRC-awareness. The master's side
instant value of @@global.binlog_checksum is stored in the dump thread's
uservar area as well as cached locally to become known in consensus by master
and slave.

Post hand-shake slave requests master for binlog dump. It sends
'COM_BINLOG_DUMP'. This command is sent to master by 'cli_advanced_command'
call. If there is some temporary network failure during this request_dump
call, 'end_server' is invoked to close the current connection between master
and slave. Upon connection close the dump thread on the master gets terminated
and it clears the 'uservar' data it got through master-slave handshake.

The 'COM_BINLOG_DUMP' command is sent once again without master-slave
handshake. Since the checksum data is not available with new dump thread a
warning gets reported.

Fix:
===
Upon network write error donot attempt reconnect, proceed to master-slave
handshake. This ensures that master is aware of slave's capability to use
checksums.
2020-07-23 12:54:40 +05:30
7bcaa541aa Merge 10.4 into 10.5 2020-05-05 21:16:22 +03:00
2c3c851d2c Merge 10.3 into 10.4 2020-05-05 20:33:10 +03:00
7fb73ed143 Merge branch '10.2' into 10.3 2020-05-04 16:47:11 +02:00
ca091e6372 Merge branch '10.1' into 10.2 2020-05-02 08:44:17 +02:00
23c6fb3e62 Merge branch '5.5' into 10.1 2020-04-30 17:36:41 +02:00
e8e67bd4a4 Bug#30689251 - BACKPORT TO MYSQL-5.6, BUG#29597896 - NULL POINTER DEREFERENCE IN LIBMYSQL
DESCRIPTION:
============
There can be issues if the packets sent by the server
are not proper. Certain checks should be performed at the
client side while unpacking fields data.

FIX:
====
Check for the appropriate fields data and error out if it
is not present.

RB: 23601
2020-04-30 10:13:21 +02:00
c1c5222cae cleanup: PSI key is *always* the first argument 2020-03-10 19:24:23 +01:00
7c58e97bf6 perfschema memory related instrumentation changes 2020-03-10 19:24:22 +01:00
a983b24407 Merge 10.4 into 10.5 2020-01-28 14:17:09 +02:00
6918157e98 Merge branch '10.3' into 10.4 2020-01-21 23:15:02 +01:00
ade89fc898 Merge branch '10.2' into 10.3 2020-01-21 09:11:14 +01:00
3a1716a7e7 Merge branch '10.1' into 10.2 2020-01-20 16:15:05 +01:00
f31bf6f094 Merge branch '5.5' into 10.1 2020-01-19 12:22:12 +01:00
4d1c1b23e1 Bug#29630767 - USE OF UNINITIALIZED VALUE IN LIBMYSQL (CLIENT.CC FUNCTION RUN_PLUGIN_AUTH) 2020-01-18 00:05:16 +01:00
28c89b7151 Merge 10.4 into 10.5 2019-12-16 07:47:17 +02:00
a15234bf4b Merge branch '10.3' into 10.4 2019-12-09 15:09:41 +01:00
2df2238cb8 Lintian complains on spelling error
The lintian check complains on spelling error:
https://salsa.debian.org/mariadb-team/mariadb-10.3/-/jobs/95739
2019-12-02 12:41:13 +02:00
f7b8d14490 cleanup: don't use my_getopt_is_args_separator()
only my_getopt should use it, because it changes my_getopt's behavior.
If one simply wants to skip the separator - don't ask it to be added
in the first place
2019-10-14 10:29:30 +02:00
49e5323dbd Merge 10.4 into 10.5 2019-06-20 09:22:10 +03:00
02979daab4 Merge 10.3 into 10.4 2019-06-19 10:49:00 +03:00
192aa295b4 Merge 10.2 into 10.3 2019-06-19 08:56:10 +03:00
10ebabc364 Windows related cleanups, remove old code.
- Do not scan registry to check if TCPIP is supported.
- Do not read registry under HKEY_LOCAL_MACHINE\SOFTWARE\MySQL anymore.
- Do not load threadpool function dynamically, it is available
since Win7.
- simplify win32_init_tcp_ip(), and return error of WSAStartup() fails.
- Correct comment in my_parameter_handler()
2019-06-18 00:37:10 +01:00
5804bb4ef0 MDEV-19750 mysql command wrong encoding
Restore the detection of default charset in command line utilities.
It worked up to 10.1, but was broken by Connector/C.

Moved code for detection of default charset from sql-common/client.c
to mysys, and make command line utilities to use this code if charset
was not specified on the command line.
2019-06-17 18:04:47 +01:00
5e4b657dd4 MDEV-18531 : Use WolfSSL instead of YaSSL as "bundled" SSL/encryption library
- Add new submodule for WolfSSL
- Build and use wolfssl and wolfcrypt instead of yassl/taocrypt
- Use HAVE_WOLFSSL instead of HAVE_YASSL
- Increase MY_AES_CTX_SIZE, to avoid compile time asserts in my_crypt.cc
(sizeof(EVP_CIPHER_CTX) is larger on WolfSSL)
2019-05-22 13:48:25 +02:00
c07325f932 Merge branch '10.3' into 10.4 2019-05-19 20:55:37 +02:00
be85d3e61b Merge 10.2 into 10.3 2019-05-14 17:18:46 +03:00
26a14ee130 Merge 10.1 into 10.2 2019-05-13 17:54:04 +03:00
c51f85f882 Merge branch '10.2' into 10.3 2019-05-12 17:20:23 +02:00
cb248f8806 Merge branch '5.5' into 10.1 2019-05-11 22:19:05 +03:00
5543b75550 Update FSF Address
* Update wrong zip-code
2019-05-11 21:29:06 +03:00
8cbb14ef5d Merge branch '10.1' into 10.2 2019-05-04 17:04:55 +02:00
e116f11f0a MDEV-18131 MariaDB does not verify IP addresses from subject alternative
names

Added a call to X509_check_ip_asc() in case server_hostname represents
an IP address.
2019-04-28 12:49:59 +02:00
f97d879bf8 cmake: re-enable -Werror in the maintainer mode
now we can afford it. Fix -Werror errors. Note:
* old gcc is bad at detecting uninit variables, disable it.
* time_t is int or long, cast it for printf's
2019-03-27 22:51:37 +01:00
93ac7ae70f Merge branch '10.3' into 10.4 2019-02-21 14:40:52 +01:00