[MDEV-10546] Make unit tests run with valgrind Created: 2016-08-11  Updated: 2016-08-11

Status: Open
Project: MariaDB Server
Component/s: None
Fix Version/s: None

Type: Task Priority: Major
Reporter: Oleksandr Byelkin Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None

Issue Links:
Relates
relates to MDEV-10455 libmariadbclient18 + MySQL-python lea... Closed
relates to MDEV-10455 libmariadbclient18 + MySQL-python lea... Closed

 Description   

It is possible to add valgrind support to mysql-test/suite/unit/suite.pm
(check $::opt_valgrind and run the command via valgrind)

The problem is that our unit test are not valgrind safe.

when the cast will be done also following test should be added:

#include "mysql.h"
#include "mysqld_error.h"
 
int main(int argc __attribute__((unused)), char **argv __attribute__((unused)))
{
  for (int i= 0; i < 5; i++)
  {
    MYSQL connection, *c= 0;
 
    c = mysql_init(&connection);
    c = mysql_real_connect(&connection,
                           "localhost", "invalid", "invalid",
                           0, 0, 0, 0);
  }
}


Generated at Thu Feb 08 07:43:03 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.