mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Initial merge result with mariaDB 10: lp:maria
This commit is contained in:
@@ -24,6 +24,9 @@
|
||||
#include "sql_acl.h" // DROP_ACL
|
||||
#include "sql_parse.h" // check_one_table_access()
|
||||
#include "sql_truncate.h"
|
||||
#ifdef WITH_WSREP
|
||||
#include "wsrep_mysqld.h"
|
||||
#endif /* WITH_WSREP */
|
||||
#include "sql_show.h" //append_identifier()
|
||||
|
||||
|
||||
@@ -531,9 +534,14 @@ bool Truncate_statement::execute(THD *thd)
|
||||
if (check_one_table_access(thd, DROP_ACL, first_table))
|
||||
DBUG_RETURN(res);
|
||||
|
||||
#ifdef WITH_WSREP
|
||||
if (WSREP(thd) && wsrep_to_isolation_begin(thd,
|
||||
first_table->db,
|
||||
first_table->table_name, NULL))
|
||||
DBUG_RETURN(TRUE);
|
||||
#endif /* WITH_WSREP */
|
||||
if (! (res= truncate_table(thd, first_table)))
|
||||
my_ok(thd);
|
||||
|
||||
DBUG_RETURN(res);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user