Skip to content

Commit

Permalink
MariaDB adjustments.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jan Lindström committed Aug 3, 2018
1 parent 3f0cd66 commit 9808e23
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
1 change: 1 addition & 0 deletions mysql-test/suite/galera/disabled.def
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,4 @@ galera_admin : MDEV-13549 Galera test failures
MW-416 : MDEV-13549 Galera test failures
galera_wan : MDEV-13549 Galera test failures
MW-388 : MDEV-13549 Galera test failures
galera#505 : Requires galera library version 25.3.24
18 changes: 15 additions & 3 deletions sql/wsrep_mysqld.cc
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,9 @@ int wsrep_init()
wsrep->provider_vendor, sizeof(provider_vendor) - 1);
}

if (!wsrep_data_home_dir || strlen(wsrep_data_home_dir) == 0)
wsrep_data_home_dir = mysql_real_data_home;

char node_addr[512]= { 0, };
size_t const node_addr_max= sizeof(node_addr) - 1;
if (!wsrep_node_address || !strcmp(wsrep_node_address, ""))
Expand Down Expand Up @@ -933,9 +936,15 @@ static bool wsrep_prepare_key_for_isolation(const char* db,
wsrep_key_arr_t* ka)
{
wsrep_key_t* tmp;
tmp= (wsrep_key_t*)my_realloc(ka->keys,
(ka->keys_len + 1) * sizeof(wsrep_key_t),
MYF(0));

if (!ka->keys)
tmp= (wsrep_key_t*)my_malloc((ka->keys_len + 1) * sizeof(wsrep_key_t),
MYF(0));
else
tmp= (wsrep_key_t*)my_realloc(ka->keys,
(ka->keys_len + 1) * sizeof(wsrep_key_t),
MYF(0));

if (!tmp)
{
WSREP_ERROR("Can't allocate memory for key_array");
Expand Down Expand Up @@ -1410,6 +1419,9 @@ static int wsrep_TOI_begin(THD *thd, char *db_, char *table_,
case SQLCOM_ALTER_EVENT:
buf_err= wsrep_alter_event_query(thd, &buf, &buf_len);
break;
case SQLCOM_DROP_TABLE:
buf_err= wsrep_drop_table_query(thd, &buf, &buf_len);
break;
case SQLCOM_CREATE_ROLE:
if (sp_process_definer(thd))
{
Expand Down

0 comments on commit 9808e23

Please sign in to comment.