Fixed errors found by MSAN

This commit is contained in:
Monty 2020-07-02 23:50:56 +03:00
parent b6ec1e8bbf
commit 53ecc354e3
4 changed files with 5 additions and 3 deletions

View File

@ -1141,6 +1141,7 @@ my_bool STDCALL mysql_embedded(void)
void my_net_local_init(NET *net)
{
net->max_packet= (uint) net_buffer_length;
net->read_timeout= net->write_timeout= 0;
my_net_set_read_timeout(net, CLIENT_NET_READ_TIMEOUT);
my_net_set_write_timeout(net, CLIENT_NET_WRITE_TIMEOUT);
net->retry_count= 1;

View File

@ -17,7 +17,7 @@ let $MYSQLD_DATADIR= `select @@datadir`;
file_exists $MYSQLD_DATADIR/mysql_upgrade_info;
--echo Run it again - should say already completed
--replace_result $MYSQL_SERVER_VERSION VERSION
--replace_regex /upgraded to .*, use/upgraded to VERSION, use/
--exec $MYSQL_UPGRADE 2>&1
# It should have created a file in the MySQL Servers datadir

View File

@ -1,3 +1,4 @@
--source include/not_as_root.inc
#
# MDEV-11883 MariaDB crashes with out-of-memory when query information_schema
#

View File

@ -2031,8 +2031,8 @@ int READ_INFO::read_xml(THD *thd)
case '=': /* attribute name end - read the value */
//check for tag field and attribute name
if(!memcmp(tag.c_ptr_safe(), STRING_WITH_LEN("field")) &&
!memcmp(attribute.c_ptr_safe(), STRING_WITH_LEN("name")))
if(!strcmp(tag.c_ptr_safe(), "field") &&
!strcmp(attribute.c_ptr_safe(), "name"))
{
/*
this is format <field name="xx">xx</field>