1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Merge branch '10.0' into 10.1

This commit is contained in:
Sergei Golubchik
2018-12-29 23:44:45 +01:00
30 changed files with 284 additions and 104 deletions

View File

@ -771,8 +771,7 @@ exit:
}
int mysql_create_db(THD *thd, char *db,
const DDL_options_st &options,
int mysql_create_db(THD *thd, char *db, DDL_options_st options,
const Schema_specification_st *create_info)
{
/*
@ -780,6 +779,9 @@ int mysql_create_db(THD *thd, char *db,
to it, we need to use a copy to make execution prepared statement- safe.
*/
Schema_specification_st tmp(*create_info);
if (thd->slave_thread &&
slave_ddl_exec_mode_options == SLAVE_EXEC_MODE_IDEMPOTENT)
options.add(DDL_options::OPT_IF_NOT_EXISTS);
return mysql_create_db_internal(thd, db, options, &tmp, false);
}
@ -1059,6 +1061,9 @@ exit:
bool mysql_rm_db(THD *thd,char *db, bool if_exists)
{
if (thd->slave_thread &&
slave_ddl_exec_mode_options == SLAVE_EXEC_MODE_IDEMPOTENT)
if_exists= true;
return mysql_rm_db_internal(thd, db, if_exists, false);
}