Do not create std::string from NULL

This commit is contained in:
Johan Wikman
2017-12-18 16:31:50 +02:00
parent 5a612be394
commit b9e7eaf3aa

View File

@ -8,7 +8,7 @@ int main(int argc, char** argv)
{
TestConnections test(argc, argv);
MYSQL *mysql = open_conn(test.maxscales->rwsplit_port[0], test.maxscales->IP[0], "testuser", NULL, false);
MYSQL *mysql = open_conn(test.maxscales->rwsplit_port[0], test.maxscales->IP[0], "testuser", "", false);
test.add_result(mysql_errno(mysql) == 0, "Connecting to MaxScale should fail");
test.add_result(strstr(mysql_error(mysql), "using password: NO") == NULL, "Missing (using password: NO) error message, got this instead: %s", mysql_error(mysql));
test.tprintf("MySQL error: %s", mysql_error(mysql));